Skip to content
Merged
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
20 changes: 18 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Codebuff
# Codebuff & Freebuff

Codebuff is an **open-source AI coding assistant** that edits your codebase through natural language instructions. Instead of using one model for everything, it coordinates specialized agents that work together to understand your project and make precise changes.
**[Codebuff](https://codebuff.com)** is an open-source AI coding assistant that edits your codebase through natural language instructions. **[Freebuff](https://www.npmjs.com/package/freebuff)** is the free, ad-supported version — no subscription, no credits, no configuration.

Instead of using one model for everything, Codebuff coordinates specialized agents that work together to understand your project and make precise changes.

<div align="center">
<img src="./assets/codebuff-vs-claude-code.png" alt="Codebuff vs Claude Code" width="400">
Expand Down Expand Up @@ -147,6 +149,18 @@ await client.run({

Learn more about the SDK [here](https://www.npmjs.com/package/@codebuff/sdk).

## Freebuff: The free coding agent

Don't want a subscription? **[Freebuff](https://www.npmjs.com/package/freebuff)** is a free variant of Codebuff — no subscription, no credits, no configuration. Just install and start coding.

```bash
npm install -g freebuff
cd your-project
freebuff
```

Freebuff is ad-supported and uses models optimized for fast, high-quality assistance. It includes built-in web research, browser use, and more. Learn more in the [Freebuff README](./freebuff/README.md).

## Why choose Codebuff

**Custom workflows**: TypeScript generators let you mix AI generation with programmatic control. Agents can spawn subagents, branch on conditions, and run multi-step processes.
Expand Down Expand Up @@ -216,6 +230,8 @@ Some ways you can help:

**SDK**: `npm install @codebuff/sdk`

**Freebuff (free)**: `npm install -g freebuff`

### Resources

**Documentation**: [codebuff.com/docs](https://codebuff.com/docs)
Expand Down
2 changes: 1 addition & 1 deletion freebuff/cli/release/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "freebuff",
"version": "0.0.21",
"version": "0.0.22",
"description": "The world's strongest free coding agent",
"license": "MIT",
"bin": {
Expand Down
65 changes: 13 additions & 52 deletions web/src/llm-api/__tests__/fireworks-deployment.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import {
DEPLOYMENT_COOLDOWN_MS,
FireworksError,
isDeploymentCoolingDown,
isDeploymentHours,
markDeploymentScalingUp,
resetDeploymentCooldown,
} from '../fireworks'
Expand Down Expand Up @@ -36,40 +35,6 @@ function dateAtEtHour(hour: number): Date {
}

describe('Fireworks deployment routing', () => {
describe('isDeploymentHours', () => {
it('returns true at 10am ET (start of window)', () => {
expect(isDeploymentHours(dateAtEtHour(10))).toBe(true)
})

it('returns true at 2pm ET (mid-day)', () => {
expect(isDeploymentHours(dateAtEtHour(14))).toBe(true)
})

it('returns true at 7pm ET (19:00, near end of window)', () => {
expect(isDeploymentHours(dateAtEtHour(19))).toBe(true)
})

it('returns false at 9am ET (before window)', () => {
expect(isDeploymentHours(dateAtEtHour(9))).toBe(false)
})

it('returns false at 8pm ET (20:00, window closed)', () => {
expect(isDeploymentHours(dateAtEtHour(20))).toBe(false)
})

it('returns false at midnight ET', () => {
expect(isDeploymentHours(dateAtEtHour(0))).toBe(false)
})

it('returns false at 3am ET', () => {
expect(isDeploymentHours(dateAtEtHour(3))).toBe(false)
})

it('returns false at 11pm ET', () => {
expect(isDeploymentHours(dateAtEtHour(23))).toBe(false)
})
})

describe('deployment cooldown', () => {
beforeEach(() => {
resetDeploymentCooldown()
Expand Down Expand Up @@ -139,8 +104,7 @@ describe('Fireworks deployment routing', () => {
return spy
}

it('uses standard API outside deployment hours', async () => {
const spy = spyDeploymentHours(false)
it('uses standard API when custom deployment is disabled', async () => {
const fetchCalls: string[] = []

const mockFetch = mock(async (_url: string | URL | Request, init?: RequestInit) => {
Expand All @@ -149,21 +113,18 @@ describe('Fireworks deployment routing', () => {
return new Response(JSON.stringify({ ok: true }), { status: 200 })
}) as unknown as typeof globalThis.fetch

try {
const response = await createFireworksRequestWithFallback({
body: minimalBody as never,
originalModel: 'minimax/minimax-m2.5',
fetch: mockFetch,
logger,
sessionId: 'test-user-id',
})

expect(response.status).toBe(200)
expect(fetchCalls).toHaveLength(1)
expect(fetchCalls[0]).toBe(STANDARD_MODEL_ID)
} finally {
spy.restore()
}
const response = await createFireworksRequestWithFallback({
body: minimalBody as never,
originalModel: 'minimax/minimax-m2.5',
fetch: mockFetch,
logger,
useCustomDeployment: false,
sessionId: 'test-user-id',
})

expect(response.status).toBe(200)
expect(fetchCalls).toHaveLength(1)
expect(fetchCalls[0]).toBe(STANDARD_MODEL_ID)
})

it('tries custom deployment during deployment hours', async () => {
Expand Down
Loading