{"id":23272874,"url":"https://github.com/mahmoudajawad/conversational_kb","last_synced_at":"2025-08-24T06:06:29.469Z","repository":{"id":268270818,"uuid":"617386930","full_name":"mahmoudajawad/conversational_kb","owner":"mahmoudajawad","description":"A PoC to created console-based chat interface to knowledge based using OpenAI gpt-3.5-turbe model","archived":false,"fork":false,"pushed_at":"2023-03-25T05:01:09.000Z","size":437,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-06T12:08:39.363Z","etag":null,"topics":["ai","chatbot","chatgpt","conversational","conversational-ai","gpt-3"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mahmoudajawad.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-03-22T09:34:46.000Z","updated_at":"2023-03-25T05:03:50.000Z","dependencies_parsed_at":null,"dependency_job_id":"005863bb-6a92-407c-a855-ff7f91b50ef9","html_url":"https://github.com/mahmoudajawad/conversational_kb","commit_stats":null,"previous_names":["mahmoudajawad/conversational_kb"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mahmoudajawad/conversational_kb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudajawad%2Fconversational_kb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudajawad%2Fconversational_kb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudajawad%2Fconversational_kb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudajawad%2Fconversational_kb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mahmoudajawad","download_url":"https://codeload.github.com/mahmoudajawad/conversational_kb/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mahmoudajawad%2Fconversational_kb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271803301,"owners_count":24824410,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-24T02:00:11.135Z","response_time":111,"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":["ai","chatbot","chatgpt","conversational","conversational-ai","gpt-3"],"created_at":"2024-12-19T19:20:06.541Z","updated_at":"2025-08-24T06:06:29.440Z","avatar_url":"https://github.com/mahmoudajawad.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Conversation KB\n\nA PoC to created console-based chat interface to knowledge based using OpenAI `gpt-3.5-turbe` model.\n\nKnowledge is provided as titled paragraphs in plain text format in `articles` directory, that is then vectorised into embeddings and saved to `embeddings` directory. With every question asked, the question is also vectorised and its embeddings are matched against the paragraphs embeddings to find three top most matches that are then appended to a `system` prompt for `gpt-3.5-turbo` model. If the question isn't the first, last top match is also appended to `system` prompt to enable follow-up questions.\n\n\n## How to Run\n\n- Add your own articles paragraphs to `articles` directory, or use provided samples from `samples` directory:\n  - Title every paragraph.\n  - Use mid-size paragraphs only.\n  - embeddings are calculated when no embeddings matching file exist, which means if you modify a file in `articles` directory that its embeddings are already calculated, you will have to manually remove the matching `embeddings` directory file to force re-calculation.\n- Create a `venv`: `python -m venv venv`.\n- Install dependencie: `python -m pip install -r requirements.txt`.\n- Run: `python .`\n\nThe project is set to emit all kind of logs, as this is a PoC that is meant to understand how such a simple approach to conversation knowledge-base would play, however, you can manually set logging level in first line of `main` function.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahmoudajawad%2Fconversational_kb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmahmoudajawad%2Fconversational_kb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmahmoudajawad%2Fconversational_kb/lists"}