https://github.com/kantord/SeaGOAT Skip to content Toggle navigation Sign up * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions For + Enterprise + Teams + Startups + Education By Solution + CI/CD & Automation + DevOps + DevSecOps Resources + Customer Stories + White papers, Ebooks, Webinars + Partners * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} kantord / SeaGOAT Public * Notifications * Fork 10 * Star 360 local-first semantic code search engine kantord.github.io/seagoat/ License MIT license 360 stars 10 forks Activity Star Notifications * Code * Issues 21 * Pull requests 3 * Discussions * Actions * Projects 0 * Security * Insights More * Code * Issues * Pull requests * Discussions * Actions * Projects * Security * Insights kantord/SeaGOAT This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main Switch branches/tags [ ] Branches Tags Could not load branches Nothing to show {{ refName }} default View all branches Could not load tags Nothing to show {{ refName }} default View all tags Name already in use A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch? Cancel Create 27 branches 88 tags Code * Local * Codespaces * Clone HTTPS GitHub CLI [https://github.com/k] Use Git or checkout with SVN using the web URL. [gh repo clone kantor] Work fast with our official CLI. Learn more about the CLI. * Open with GitHub Desktop * Download ZIP Sign In Required Please sign in to use Codespaces. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Launching Xcode If nothing happens, download Xcode and try again. Launching Visual Studio Code Your codespace will open once ready. There was a problem preparing your codespace, please try again. Latest commit github-actions 0.29.0 ... e4b7acc Sep 20, 2023 0.29.0 Automatically generated by python-semantic-release e4b7acc Git stats * 449 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time .github/workflows chore(deps): update python-semantic-release/python-semantic-release a... September 20, 2023 15:28 asciinema docs: add titles to slideshow gif September 9, 2023 15:28 assets docs: add titles to slideshow gif September 9, 2023 15:28 docs docs: document query API September 18, 2023 22:31 seagoat 0.29.0 September 20, 2023 14:09 tests feat: include isRunning for server-info September 18, 2023 16:18 typings/git feat: allow returning list of files June 20, 2023 21:54 .gitignore feat: add --context/--context-above-/--context-below August 18, 2023 17:15 .licrc perf: use server to make all queries July 16, 2023 15:36 .markdownlintignore chore: don't markdownlint CHANGELOG.md July 18, 2023 16:11 .pre-commit-config.yaml feat: analyze all files using the queue August 30, 2023 22:48 .pylintrc feat: group results together when printing with bat September 1, 2023 18:12 CHANGELOG.md 0.29.0 September 20, 2023 14:09 LICENSE docs: add license July 11, 2023 19:02 README.md feat: support .cc and .cxx files September 20, 2023 16:07 SECURITY.md docs: fix too long lines in SECURITY.md September 8, 2023 21:21 mkdocs.yml feat: allow running server on custom port August 21, 2023 20:34 poetry.lock chore(deps): update dependency mkdocs-material to v9.3.2 (#217) September 20, 2023 15:24 poetry.toml feat: allow returning list of files June 20, 2023 21:54 pyproject.toml 0.29.0 September 20, 2023 14:09 renovate.json feat: add --version to seagoat-server August 19, 2023 19:33 View code [ ] SeaGOAT Getting started Install SeaGOAT System requirements Hardware Oporating system Start SeaGOAT server Search your repository Stopping the server Development Install dependencies Running tests Watch mode (recommended) Test changed files Test all files Manual testing FAQ How does SeaGOAT work? Does it send my data to ChatGPT? Why does SeaGOAT need a server? Does SeaGOAT create AI-derived work? Is SeaGOAT ethical? What programming langauges are supported? README.md Logo SeaGOAT A code search engine for the AI age. SeaGOAT is a local search tool that leverages vector embeddings to enable to search your codebase semantically. [demo-slide] Note: I was recently laid off my job and I am looking for new opportunities. If you need a Senior Full Stack Developer, contact me! I have experience with React, Node and Python and I'm located in Spain (European Union). 10+ years in software development professionally. Getting started Install SeaGOAT In order to install SeaGOAT, you need to have the following dependencies already installed on your computer: * Python 3.11 or newer * ripgrep * bat (optional, highly recommended) When bat is installed, it is used to display results as long as color is enabled. When SeaGOAT is used as part of a pipeline, a grep-line output format is used. When color is enabled, but bat is not installed, SeaGOAT will highlight the output using pygments. Using bat is recommended. To install SeaGOAT using pipx, use the following command: pipx install seagoat System requirements Hardware Should work on any decent laptop. Oporating system SeaGOAT is designed to work on Linux (tested ), macOS (partly tested, help ) and Windows (help needed ). Start SeaGOAT server In order to use SeaGOAT in your project, you have to start the SeaGOAT server using the following command: seagoat-server start /path/to/your/repo Search your repository If you have the server running, you can simply use the gt or seagoat command to query your repository. For example: gt "Where are the numbers rounded" You can also use Regular Expressions in your queries, for example gt "function calc_.* that deals with taxes" Stopping the server You can stop the running server using the following command: seagoat-server stop /path/to/your/repo Development Requirements: * Poetry * Python 3.11 or newer * ripgrep Install dependencies After cloning the repository, install dependencies using the following command: poetry install Running tests Watch mode (recommended) poetry run ptw Test changed files poetry run pytest . --testmon Test all files poetry run pytest . Manual testing You can test any SeaGOAT command manually in your local development environment. For example to test the development version of the seagoat-server command, you can run: poetry run seagoat-server ~/path/an/example/repository FAQ The points in this FAQ are indications of how SeaGOAT works, but are not a legal contract. SeaGOAT is licensed under an open source license and if you are in doubt about the privacy/safety/etc implications of SeaGOAT, you are welcome to examine the source code, raise your concerns, or create a pull request to fix a problem. How does SeaGOAT work? Does it send my data to ChatGPT? SeaGOAT does not rely on 3rd party APIs or any remote APIs and executes all functionality locally using the SeaGOAT server that you are able to run on your own machine. Instead of relying on APIs or "connecting to ChatGPT", it uses the vector database called ChromaDB, with a local vector embedding engine and telemetry disabled by default. Apart from that, SeaGOAT also uses ripgrep, a regular-expression based code search engine in order to provider regular expression/ keyword based matches in addition to the "AI-based" matches. While the current version of SeaGOAT does not send your data to remote servers, it might be possible that in the future there will be optional features that do so, if any further improvement can be gained from that. Why does SeaGOAT need a server? SeaGOAT needs a server in order to provide a speedy response. SeaGOAT heavily relies on vector embeddings and vector databases, which at the moment cannot be replace with an architecture that processes files on the fly. It's worth noting that you are able to run SeaGOAT server entirely locally, and it works even if you don't have an internet connection. This use case does not require you to share data with a remote server, you are able to use your own SeaGOAT server locally, albeit it's also possible to run a SeaGOAT server and allow other computers to connect to it, if you so wish. Does SeaGOAT create AI-derived work? Is SeaGOAT ethical? If you are concerned about the ethical implications of using AI tools keep in mind that SeaGOAT is not a code generator but a code search engine, therefore it does not create AI derived work. That being said, a language model is being used to generate vector embeddings. At the moment SeaGOAT uses ChromaDB's default model for calculating vector embeddings, and I am not aware of this being an ethical concern. What programming langauges are supported? Currently SeaGOAT is hardcoded to only process files in the following formats: * Text Files (*.txt) * Markdown (*.md) * Python (*.py) * C (*.c, *.h) * C++ (*.cpp, *.cc, *.cxx, *.hpp) * TypeScript (*.ts, *.tsx) * JavaScript (*.js, *.jsx) * HTML (*.html) * Go (*.go) * Java (*.java) * PHP (*.php) * Ruby (*.rb) About local-first semantic code search engine kantord.github.io/SeaGOAT/ Topics ai regular-expression embeddings code-search grep ripgrep code-search-engine grep-like vector-database vector-embeddings llm Resources Readme License MIT license Security policy Security policy Activity Stars 360 stars Watchers 4 watching Forks 10 forks Report repository Releases 85 v0.29.0 Latest Sep 20, 2023 + 84 releases Packages 0 No packages published Contributors 7 * @kantord * @actions-user * @renovate[bot] * @photonbit * @tanishq-dubey * @ldhough Languages * Python 99.6% * Shell 0.4% Footer (c) 2023 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact GitHub * Pricing * API * Training * Blog * About You can't perform that action at this time.