{"id":15103661,"url":"https://gitlab.com/tangibleai/community/qary-cli","last_synced_at":"2026-01-02T12:37:34.080Z","repository":{"id":57458802,"uuid":"17574077","full_name":"tangibleai/community/qary-cli","owner":"tangibleai","description":"Command Line Interface for developers of qary -- the open source, teachable AI assistant that truly assists, rather than manipulating you.","archived":false,"fork":false,"pushed_at":null,"size":null,"stargazers_count":18,"open_issues_count":70,"forks_count":24,"subscribers_count":null,"default_branch":"main","last_synced_at":"2025-04-23T09:08:26.740Z","etag":null,"topics":["BERT","ELIZA","GPT3","HACKTOBERFEST2022","NLP","Virtual Assistant","chatbot","datasets","hacktoberfest","machine learning","pytorch","sklearn","spacy","torch"],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"hippocratic-2.1","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://gitlab.com/uploads/-/system/project/avatar/17574077/1_1_.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-03-18T23:42:59.027Z","updated_at":"2025-04-02T12:43:51.345Z","dependencies_parsed_at":"2022-09-10T08:40:11.014Z","dependency_job_id":null,"html_url":"https://gitlab.com/tangibleai/community/qary-cli","commit_stats":null,"previous_names":["tangibleai/qary"],"tags_count":116,"template":null,"template_full_name":null,"purl":"pkg:gitlab/tangibleai/qary-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/tangibleai%2Fcommunity%2Fqary-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/tangibleai%2Fcommunity%2Fqary-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/tangibleai%2Fcommunity%2Fqary-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/tangibleai%2Fcommunity%2Fqary-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/owners/tangibleai","download_url":"https://gitlab.com/tangibleai/community/qary-cli/-/archive/main/qary-cli-main.zip","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories/tangibleai%2Fcommunity%2Fqary-cli/sbom","host":{"name":"gitlab.com","url":"https://gitlab.com","kind":"gitlab","repositories_count":4518950,"owners_count":6979,"icon_url":"https://github.com/gitlab.png","version":null,"created_at":"2022-05-30T11:31:42.605Z","updated_at":"2024-07-18T11:24:13.055Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/gitlab.com/owners"}},"keywords":["BERT","ELIZA","GPT3","HACKTOBERFEST2022","NLP","Virtual Assistant","chatbot","datasets","hacktoberfest","machine learning","pytorch","sklearn","spacy","torch"],"created_at":"2024-09-25T19:41:18.673Z","updated_at":"2026-01-02T12:37:34.040Z","avatar_url":"https://gitlab.com/uploads/-/system/project/avatar/17574077/1_1_.png","language":null,"funding_links":["https://buymeacoffee.com/hobs"],"categories":[],"sub_categories":[],"readme":"[![Buy Us Tea](https://github.com/nlpia/nlpia-bot/raw/develop/docs/media/small-leaf-and-name-screenshot-31x80.png)](https://buymeacoffee.com/hobs)\n[![PyPI version](https://img.shields.io/pypi/pyversions/qary.svg)](https://pypi.org/project/qary/)\n[![License](https://img.shields.io/pypi/l/qary.svg)](https://pypi.python.org/pypi/qary/)\n[![codecov](https://codecov.io/gl/tangibleai/qary/branch/master/graph/badge.svg)](https://codecov.io/gl/tangibleai/qary)\n[![DigitalOcean Referral Badge](https://web-platforms.sfo2.digitaloceanspaces.com/WWW/Badge%202.svg)](https://www.digitalocean.com/?refcode=5bc34fba1bee\u0026utm_campaign=Referral_Invite\u0026utm_medium=Referral_Program\u0026utm_source=badge)\n\n\n# `qary`\n\nThe `qary` package is both a chatbot framework and a virtual assistant that actually assists!\nMost bots manipulate you to make money for their corporate masters. With qary, you can build **your** bot to protect you and amplify your prosocial intelligence.\n\nWe started work on `qary` as part of 1st editition of [NLP in Action](https://proai.org/nlpia2-book).\nIt has slowly grown into the core framework for a social-impact startup [Tangible AI](https://tangibleai.com).\nTangible AI [interns and volunteers](/docs/wiki/contributors.md) are constantly fixing bugs, adding new features and dialog trees to qary's repetoire.\nThe [San Diego Python User Group](https://www.pythonsd.org/index.html) meetups have been the scene for [some fun qary demos](https://piped.kavin.rocks/channel/UCXU-oZwaHnoYUhja_yrrrGg).\nThe [San Diego Machine Learning Book Club](https://www.meetup.com/San-Diego-Machine-Learning/) is a great place for support on advanced concepts in the _NLP in Action_ book or anything NLP and machine learning related.\nYou can find more ideas in `docs/`.\n\n## Install\n\n### Install from source\n\nRetrieve the source code from GitLab using a bash console:\n\n```bash\ngit clone git@gitlab.com:tangibleai/qary\ncd qary\n```\n\nIf that doesn't work or you don't know what a bash console is, then you probably want to start with the **Windows Users** Instructions here: [docs/README-windows-install.md](docs/README-windows-install.md)\n\nMake sure you install `qary` in a _virtual environment_ using the latest version of `pip` and the python `virtualenv` package:\n\n```bash\npip install --upgrade pip virtualenv\npython -m virtualenv venv\nsource venv/bin/activate\n```\n\nNow that you have your environment activated, make sure you are in the `qary/` repository along side the pyproject.toml file so you can install qary in developer (editable) mode:\n\n```bash\npip install --editable .\n```\n\nNow you're ready to run `qary` from the command line (bash console):\n\n```bash\nqary \"Hi!\"\n```\n\n### PyPi package\n`qary` is on [PyPi](https://pypi.org/project/qary/) but this install is unlikely to work, unless you've already installed all the dependencies:\n\n```bash\npip install qary\n```\n\n## Usage\n\n```bash\n$ qary --help\nusage: qary [-h] [--version] [--name STR] [-p] [-s STR] [-v] [-vv] [words [words ...]]\n```\n\n### Running `qary` for just one skill\n\n```bash\n$ qary -s qa\n# ... (logging messages)\nYOU: When was Barack Obama born?\n# ... (logging messages)\nqary: August 4, 1961\n```\n\n### `qary` skills\n\n`qary`'s probabilistic conversation manager chooses a reply from the possiblities generated by the different personalities:\n\n- `pattern` (`skills/pattern.py`): example skill using regex patterns to reply to greetings like \"hi\"\n- `qa` (`skills/qa.py`): BERT and ALBERT Wikipedia Question Answering (WikiQA reading comprehension tests)\n- `faq` (`skills/faq.py`): answers to frequently asked questions using data/faq/*.yml\n- `glossary` (`skills/glossary.py`): definitions from glossary yml files in data/faq/glossary-*.yml\n- `eliza` (`eliza.py`): a python port of the ELIZA therapist bot\n\n### Configuring default personalities\n\nBy default, `qary` runs with `qa` personality. Check out the config file in `qary.ini` to change the default skills loaded for your own custom skill in the skills directory.\n\n## Approach\n\n`qary`'s chatbot framework allows you to combine many approaches to give you state-of-the-art capability to answer questions and carry on a conversation:\n\n1. search: [chatterbot](https://github.com/gunthercox/ChatterBot), [will](https://github.com/skoczen/will)\n2. pattern matching and response templates: Alexa, [AIML](https://github.com/keiffster/program-y)\n3. generative deep learning: [robot-bernie](https://github.com/nlpia/robot-bernie), [movie-bot](https://github.com/totalgood/nlpia/blob/master/src/nlpia/book/examples/ch10_movie_dialog_chatbot.py)\n4. grounding: [snips](https://github.com/snipsco/snips-nlu)\n\nIt's all explained in detail at [NLP in Action](https://www.manning.com/books/natural-language-processing-in-action).\n\nPresentations for San Diego Python User Group are in [docs/](/docs/2019-08-22--San Diego Python User Group -- How to Build a Chatbot.odp) and on the web at [http://totalgood.org/midata/talks](http://totalgood.org/midata/talks/)\n\n## Contributing pattern for developers\n\nDM @hobs on SD PUG's [discord server](https://discord.gg/yFTAQDxg) if you'd like to join us for weekly collaborative-coding sessions on `qary` and other open source projects.\n\n1. [Create a fork](https://docs.gitlab.com/ee/user/project/repository/forking_workflow.html#creating-a-fork) of the [main qary repository](https://gitlab.com/tangibleai/qary) on Gitlab.\n2. Make your changes in a branch named something different from `master`, e.g. create\n   a new branch `my-pull-request`.\n3. [Create a merge request](https://docs.gitlab.com/ee/user/project/merge_requests/creating_merge_requests.html).\n4. Help your fellow contributors out by:\n  - Follow the [PEP-8 style guide](https://www.python.org/dev/peps/pep-0008/).\n  - Try to include a docstring, at least a single line, in any function, method, or class\n  - Bonus points for adding a [doctest](https://docs.python.org/3/library/doctest.html) as part of your contribution.\n  - If you add a new feature, write some quick docs in the README.\n  - Add your name and attribution to the AUTHORS file.\n  - Know we are grateful for your contribution! You've made the chatbot world a little better!\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/gitlab.com%2Ftangibleai%2Fcommunity%2Fqary-cli","html_url":"https://awesome.ecosyste.ms/projects/gitlab.com%2Ftangibleai%2Fcommunity%2Fqary-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/gitlab.com%2Ftangibleai%2Fcommunity%2Fqary-cli/lists"}