Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Google Gemini API Key for LLM TODO solver
# Get your API key from: https://ai.google.dev/gemini-api/docs/api-key
GOOGLE_API_KEY=your_google_api_key_here
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ LICENSE
yarn.lock
package-lock.json

# Environment variables (contains API keys)
.env
.env.local

compiled
/doc
Expand Down
44 changes: 44 additions & 0 deletions LLM_SETUP.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# LLM TODO Solver Setup

This project uses Google's Gemini API for LLM-powered TODO solving in Pie code.

## Setup Instructions

1. **Get a Google Gemini API Key**
- Visit: https://ai.google.dev/gemini-api/docs/api-key
- Sign in with your Google account
- Create a new API key

2. **Configure the API Key**
- Copy `.env.example` to `.env`:
```bash
cp .env.example .env
```
- Edit `.env` and replace `your_google_api_key_here` with your actual API key:
```
GOOGLE_API_KEY=your_actual_api_key_here
```

3. **Run Tests**
```bash
npm test -- test_llm.ts
```

## Important Notes

- **Never commit `.env` file to git** - it's already in `.gitignore`
- The `.env.example` file is safe to commit (it has no real key)
- If you get an error about missing API key, make sure `.env` file exists and contains your key

## Free Tier Limits

Google Gemini free tier has rate limits:
- 10 requests per minute
- If you hit the limit, tests will fail with quota errors
- Wait a minute and try again

## Security

- Keep your API key private
- Don't share it in commits, screenshots, or public channels
- If accidentally exposed, regenerate a new key immediately
2 changes: 1 addition & 1 deletion dist/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

Loading