Skip to main content

A context-aware coding assistant for everyone. Students, learners, anyone who doesn't want to pay for subscriptions.

Project description

Scrappy

Tests PyPI version License: MIT

23,000+ free AI coding requests per day. No subscriptions. No credit card. No geographic restrictions.

Scrappy orchestrates free-tier LLM providers (Cerebras, Groq, Gemini) into a context-aware coding assistant that understands your entire codebase.

Scrappy showing a diff preview before applying changes Scrappy shows diffs before making changes. You approve or reject each edit.


The Mission: AI for Everyone

Paid AI tools are great, but $20/month adds up. Scrappy exists for:

  • Students - Learn to code with AI help, without the subscription
  • Developers in restricted regions - Where payments are blocked or $20 is significant
  • Frugal folks - Build and learn without subscriptions.

Why Scrappy?

Tool Cost Context-Aware Agent Mode Offline Index
Scrappy Free Yes Yes Yes
ChatGPT Plus $20/mo No No No
Claude Pro $20/mo Limited Yes No
GitHub Copilot $10/mo Yes No No
Aider Free* Yes Yes No
Continue Free* Yes No No

* Requires your own API keys with usage-based billing. Scrappy uses providers with generous free tiers.


What You Get

  • Context-aware chat - Scrappy indexes your codebase locally; it knows your functions, classes, and patterns
  • Agent mode - /agent executes multi-step tasks with human approval at each step
  • Diff preview - See exactly what changes before they're applied (shown above)
  • Automatic checkpoints - Git-based rollback if anything goes wrong
  • Provider failover - When one API hits rate limits, Scrappy switches to another
  • Offline search - After initial setup, semantic code search runs entirely on your machine
  • Session persistence - Conversations auto-save; pick up where you left off

Quick Start

1. Install

pip install scrappy-ai

Or with a virtual environment:

# Mac/Linux
python3 -m venv venv && source venv/bin/activate && pip install scrappy-ai

# Windows (PowerShell)
python -m venv venv; .\venv\Scripts\activate; pip install scrappy-ai

2. Get Free API Keys

You need at least one (all three recommended for 23K+ daily requests):

Provider Free Tier Get Key
Cerebras 14,400 req/day cloud.cerebras.ai
Groq 7,000+ req/day console.groq.com
Gemini 1,650 req/day aistudio.google.com

No credit card required for any of them.

3. Run

cd your-project
scrappy

First run:

  1. Paste your API keys (stored locally, never sent anywhere)
  2. Scrappy downloads the embedding model (~33MB, one-time)
  3. Your codebase indexes in the background
  4. Start chatting immediately - no need to wait for indexing

Usage Examples

Chat Mode (default)

You: How does the authentication flow work?
You: What files handle database connections?
You: Explain the error handling in src/api/

Agent Mode

You: /agent add input validation to the signup form
You: /agent refactor UserService to use dependency injection
You: /agent write tests for the payment module

Agent mode shows you each proposed change as a diff. You approve, reject, or modify before anything is written.

Commands

/agent <task>    Run the coding agent with human approval
/help            Show all commands
/clear           Clear conversation history
/quit            Exit

See CLI Documentation for the full reference.


How It Works

  1. Indexing: BGE-small embeddings (33MB, runs locally) index your codebase into LanceDB
  2. Retrieval: Your questions trigger semantic search to find relevant code
  3. Orchestration: Scrappy routes requests across providers, handling rate limits automatically
  4. Response: Context-aware answers that understand your specific codebase

For the full architecture, see ARCHITECTURE.md.


FAQ

  • Q: Is this really free?

    • A: Yes. Cerebras, Groq, and Google offer generous free tiers. Scrappy just orchestrates them intelligently.
  • Q: What happens when rate limits hit?

    • A: Scrappy automatically fails over to the next available provider. With all three configured, you're unlikely to hit limits in normal use.
  • Q: Is my code private?

    • A: Scrappy has no servers. Code snippets are sent to the LLM providers (Cerebras/Groq/Google) to generate responses. Check their privacy policies. The local index never leaves your machine.
  • Q: What languages does it support?

    • A: All of them. The semantic search and LLMs are language-agnostic.
  • Q: Does it work offline?

    • A: Chat requires internet (to reach LLM APIs). Code indexing and search are fully offline after the initial 33MB model download.
  • Q: What if a provider removes their free tier?

    • A: Scrappy is modular. New providers can be added easily. As long as any free tier exists, Scrappy works.

Requirements

  • Python 3.11+
  • Git (for undo)
  • Windows, macOS, or Linux

Troubleshooting

"No API keys configured" Run scrappy and follow the setup wizard to add at least one key.

"Rate limit exceeded" Add more providers, or wait for the limit to reset (usually hourly/daily).

Indexing seems slow Large codebases take time on first run. Subsequent runs are incremental and fast.

Model download fails Check your internet connection. The BGE-small model downloads from Hugging Face.


Contributing

Contributions welcome! Please see CONTRIBUTING.md for guidelines.


Disclaimer

Use at your own risk. Always work from a clean git state so you can revert if needed. Scrappy creates checkpoints, but git is your ultimate safety net.


License

MIT License. Use it, modify it, share it.


If Scrappy helps you, star the repo so others can find it.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

scrappy_ai-1.3.0.tar.gz (625.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

scrappy_ai-1.3.0-py3-none-any.whl (712.2 kB view details)

Uploaded Python 3

File details

Details for the file scrappy_ai-1.3.0.tar.gz.

File metadata

  • Download URL: scrappy_ai-1.3.0.tar.gz
  • Upload date:
  • Size: 625.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.1

File hashes

Hashes for scrappy_ai-1.3.0.tar.gz
Algorithm Hash digest
SHA256 8933cf86540be8a9494a6c093eeed7d64cddf2a6fbee4c4db1e3ca04c82ab32c
MD5 3a93573e157532ca5fa013423e079d28
BLAKE2b-256 d0a988517c7f00fc12f17147dc589270831b28b45372fd6037e00e14614de4a1

See more details on using hashes here.

File details

Details for the file scrappy_ai-1.3.0-py3-none-any.whl.

File metadata

  • Download URL: scrappy_ai-1.3.0-py3-none-any.whl
  • Upload date:
  • Size: 712.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.1

File hashes

Hashes for scrappy_ai-1.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 622b0b86dcaa6362cdafa3b45fd68dde5da56060da557c01c29da3ec4bb17479
MD5 0e66de6af9224a09c8c68b6c3938ac2c
BLAKE2b-256 a62482d589de5a0578bd7eef455ca77394f766297a21d116f7be1dacd5d7d8d7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page