{"id":20630166,"url":"https://github.com/sdebby/telegraph","last_synced_at":"2026-05-09T07:34:14.135Z","repository":{"id":211315336,"uuid":"728768128","full_name":"sdebby/telegraph","owner":"sdebby","description":"Telegraph project- lets talk to ChatGPT","archived":false,"fork":false,"pushed_at":"2023-12-09T15:03:53.000Z","size":53506,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-15T18:54:46.542Z","etag":null,"topics":["chatgpt","diy-project","hardware","openai","python","raspberry-pi"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sdebby.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-07T16:45:49.000Z","updated_at":"2023-12-10T17:16:25.000Z","dependencies_parsed_at":"2025-03-08T17:37:24.718Z","dependency_job_id":null,"html_url":"https://github.com/sdebby/telegraph","commit_stats":null,"previous_names":["sdebby/telegraph"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/sdebby/telegraph","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdebby%2Ftelegraph","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdebby%2Ftelegraph/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdebby%2Ftelegraph/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdebby%2Ftelegraph/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sdebby","download_url":"https://codeload.github.com/sdebby/telegraph/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdebby%2Ftelegraph/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32811484,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"online","status_checked_at":"2026-05-09T02:00:06.633Z","response_time":123,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chatgpt","diy-project","hardware","openai","python","raspberry-pi"],"created_at":"2024-11-16T14:07:05.960Z","updated_at":"2026-05-09T07:34:14.129Z","avatar_url":"https://github.com/sdebby.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TELEGRAPH project\r\n\r\n## Wikipedia [link](https://en.wikipedia.org/wiki/History_of_the_telephone)\r\n\r\n## About\r\nLets have a chat with ChatGPT4,\r\n\r\nBUT for **REAL**,\r\n\r\nLets have a call.\r\n\r\nWe are best friends. \r\n\r\nThis script is using OpenAI STT, chat and TTS models, to have a real feeling chat.\r\n\r\n## Equipment:\r\n- Raspberry pi 3 B\r\n- USB headset (microsoft LiveChat)\r\n- Switch\r\n- 5 mm LED\r\n- 2 X 220 kOhm resistors\r\n- Old wireless telephone.\r\n\r\n## The process (Connecting the hardware):\r\n![telephone](https://github.com/sdebby/telegraph/blob/main/Media/panasonic_dect_brezzicni_telefon_kx_tg1611fxh_PKKX-TG1611FXH.jpeg?raw=true)\r\n1. Taking apart an old DECT telephone.\r\n   \r\n![telephone open 1](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7527.jpg?raw=true)\r\n\r\n![telephone open 2](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7525.jpg?raw=true)\r\n\r\n2. Disconnecting speaker\r\n\r\n![Speaker](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7528.jpg?raw=true)\r\n\r\n3. Soldering LED + resistors + switch to cable.\r\n\r\n![LED](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7529.jpg?raw=true)\r\n\r\n![Switch](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7532.jpg?raw=true)\r\n\r\n4. Disassemble USB headset:\r\n\r\n![Headset](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7534.jpg?raw=true)\r\n\r\n5. Testing cable on raspberry pi.\r\n\r\n![LED](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7535.jpg?raw=true)\r\n\r\n6. Soldering USB speaker and microphone wires to telephone, adhering the button to back cover with hot glue and adhering the LED to front cover with hot glue.\r\n   \r\n![The connection](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7536.jpg?raw=true)\r\n\r\n7. Closing all together.\r\n\r\n![all together 1](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7541.jpg?raw=true)\r\n\r\n![all together 2](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7542.jpg?raw=true)\r\n\r\n![all together 3](https://github.com/sdebby/telegraph/blob/main/Media/IMG_7543.jpg?raw=true)\r\n\r\n### Schematics\r\n![schematics](https://github.com/sdebby/telegraph/blob/main/Media/schematic_bb.jpg?raw=true)\r\n\r\n## Behind the scenes:\r\n1. If there where old message files, they will be deleted from the folder.\r\n2. A pre recorded welcome message will play to the user.\r\n3. User press the button and record a new message.\r\n4. When releasing the button, the message converted to MP3 and sent to OpenAI Whisperer module - Speech To Text (STT).\r\n5. The replied transcript then sent to OpenAI ChatGPT 4 module.\r\n6. The replied generated text then sent to OpenAI Text To Speech module (TTS).\r\n7. The replied MP3 then converted to WAV and played back to the user.\r\n\r\n## Demo video\r\n\r\n[![](https://markdown-videos-api.jorgenkh.no/youtube/m34_VWeIYn8)](https://youtu.be/m34_VWeIYn8)\r\n\r\n## Install:\r\nInstall ffmpeg on machine:\r\n\r\nhttps://ffmpeg.org/\r\n\r\n```bash\r\ngit clone sdebby/telegraph\r\npip install -r requirements.txt\r\npython ChatWithLinux1.py -d [x]\r\n```\r\nObtain Open AI API key and save in in environment as \"OpenAI_Key\" (or replace the key in file OpenAIHelper.py)\r\n\r\n### Usage\r\nparameters:\r\n\r\n-h help \r\n\r\n-l list of USB devices\r\n\r\n-d [x] use USB device no. x\r\n\r\n- If using a Raspberry pi (like in this project) and need to adjust volume:\r\n```bash\r\nalsamixer\r\n- Adjust USB device volume and exit\r\n- Save configuration: \r\nsudo alsactl store\r\n```\r\n\r\n### Limitations:\r\n- Due to the ping-pong method (sending voice,receiving text, sending text, ect ...) there is a long delay from when talking to receiving answer.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsdebby%2Ftelegraph","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsdebby%2Ftelegraph","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsdebby%2Ftelegraph/lists"}