# Project export: BeeWork

This document was generated by HackStack to give an AI agent context about a hackathon project. Sections are labeled with their provenance; content marked as truncated was cut to keep this document small.

## Project metadata

- Hackathon: TreeHacks 2026
- Tagline: A Browser Agent Hive that Builds Knowledge Bases
- Devpost: https://devpost.com/software/beework
- GitHub: https://github.com/Alezander9/BeeWork
- Demo: http://beework.cc/
- Video: https://www.youtube.com/embed/YL_5W60JScc?enablejsapi=1&hl=en_US&rel=0&start=&version=3&wmode=transparent
- Team: 2 GitHub contributor(s) — Alezander9 (34 commits), Kumar.s.Chandra (26 commits)

## Devpost submission (written by the team)

### Inspiration

Deep Research agents are extremely promising. aspects of LLMs, but they have some key issues. 1 A basic LLM can tell you something, but it is not verifiable. It has fuzzy knowledge of the entire internet, but you cannot ask it how it knows what it knows. Worse, LLMs tend to be confidently incorrect. For fields like medicine, law, or trading, this is unacceptable. 2 Any agent that uses the internet quickly runs into the context problem. A single site can easily exceed 500k tokens of information. Current implementations either read the first ~10k tokens of many sites or read fully only one or two. We beat this context window with our project: BeeWork. Imagine if you could had AI agent with more knowledge than a domain expert?

### What it does

For an Agent to be a domain expert, it needs a source of concise, structured, and cited information. We call that a knowledgebase. A knowledge base is like a wiki, it has citations to primary sources and links to other pages within the wiki. An agent can search with grep, navigate to linked pages, and visit primary sources to verify information. The best LLM is one with the best context. Our knowledge base is a filesystem of .md files hosted on GitHub. Agents like filesystems, they understand them natively. We also host our knowledgebase on GitHub. Agents also like git, they can use git commands flawlessly, know how to deal with merge conflicts, and GitHub records all changes and attributions. Here is how BeeWork uses many agents working together to create a knowledgebase. 1. Project requirements We start with a handwritten file called PROJECT.md of what the knowledgebase needs to be about 2. Orchestrator (Queen Bee Agent) The orchestrator reads PROJECT.md searches the web with Parallel, reading shallowly (just 2000 tokens) from many sites over many search queries. This gives it a broad understanding, which it uses to define the folders of the repo, like companies/, risks/ or regulations/. Then it creates a list of several questions for each site that appeared in searches, like "Look on https://www.waterworld.com/ for information on the economic feasibility of WWTP biogas upgrading." 3. Researcher (Worker Bee) Each one of these >100 research questions gets sent to a Browser Use agent that visits the page like a real person, interacting and searching for the target information. Every page that it visits along the way is recorded for attribution. The results are written as a file along with citations. Then the agent clones the knowledgebase, reads existing relevant files, and edits them to add in new information. This is submitted as a pull request. 4. Reviewer (House Bee) Every pull request is reviewed by another agent. This agent serves to validate the added information, check for formatting mistakes, missing or invalid citations, and evaluate the overall quality and novelty of the contribution. Because this agent does not have the context and goal pollution of the raw website data, it improves the quality of the pull requests with edits and rejects ones that do not meet our standards. It also handles merge conflicts. AI Consultant (Chat GBeeT) Finally, we have a single agent with access to the knowledgebase who can answer questions about this domain with expert and cited responses. While this chat agent is the actually useful part for end consumers, our innovation lies in the agents that work together to create and maintain the knowledgebase this chat agent relies on.

### How we built it

Every agent is a OpenCode agent running in a Modal sandbox. Coding agents are really good. In fact, we believe they are better than plain tool calling agents even at calling tools. So every "tool" we make for our agent is actually just a python script, that the coding agent can read, run, or edit with its coding and terminal primitives. This completely unbinds the agent to adapt to and fix unexpected conditions. And the sandbox takes care of any safety concerns. We tuned each of our agents using Laminar, a fullstack observability tool for Agents. It shows us every command and message our agents run, and enables us to make tweaks to the system prompts to make each one more efficient and effective. The browser agents are run on Browser Use cloud, which has effective and fast actions, and handles stealth and authentication very well, allowing us to visit sites that other browser agents get blocked at. We also made a frontend observability tool and made it bee themed. It showcases the status of each knowledgebase, browser agent, reviewer, and has a chat interface where the AI Consultant with knowledgebase, plain LLM, and LLM with search respond in parallel for comparison. To view the actual knowledgebases themselves, we use Obsidian, a great application for viewing linked markdown files. We especially like the graph view. We considered using the Claude Code agent SDK for the prize, but we prefer open source so used OpenCode. For LLMs, we found Claude Opus 4.6 works best for orchestrator and reviewer, and Gemini 3 flash was best for the workers. But we ran out of anthropic credits quickly so we used Gemini for everything. For coding we made a monorepo with one folder per agent with sandbox config, the system prompt and the useful tools as python files. The agent is given its folder in a sandbox and told "Read AGENTS.md and use tools in tools/ to complete your task." This was a very generalizable and effective agent framework. Alex used Cursor and Kumar used Antigravity, both with Claude Opus 4.6. We read every line of code to ensure quality, total spend was about $50. In the 36 hours for the hackathon, we worked for 28.5.

### Challenges we ran into

Combining the deep results of many browser agents into a structure that is more accurate and more concise than the sum of its parts is the main challenge we faced. Adding and tuning the reviewer agents as adversaries to the workers is what really solved this for us, and when we started to be amazed by the knowledgebases produced. The challenge that we did not expect is that once we started testing >50 concurrent agents all pushing to the same github from different sandboxes, our google and github account for our agent were abruptly terminated for suspicious behavior and the accounts and all data were deleted. We lost all of our knowledgebases, 30 mins before the deadline. We made another account and rebuilt, but it also got deleted midway during judging. Moving forward, we will have to get an enterprise GitHub account for the bot, or host git on our own server.

### Accomplishments we're proud of

We are really proud of the quality of knowledgebases produced. In our demo video, we create a very small knowledgebase about Alzheimer's, and ask the AI Consultant a question from a premed friend. The Agent with our knowledgebase had a more accurate answer than plain LLM and a search Agent. Furthermore, since our agent cited the original source we got to visit the original paper and verify the finding. When we did, we realized that the plain and search LLM were reporting the result in the paper's abstract (a shallow read into the page) but our agent had the additional information only found later in the paper. We really believe that knowledgebases are the future of AI intelligence in areas where you cannot afford to have any inaccurate information. We have a larger knowledgebase (recovered partially after GitHub deleted our bot) about renewable gas in California that you can view yourself here: https://github.com/Alezander9/RenewableGasCalifornia

### What's next

stanford roomates -> lovers -> cofounders

## README (from the GitHub repository)

![Bee Work Splash](frontend/src/assets/BeeWorkSplash.jpg)

Project for Treehacks 2026

BeeWork
Unleashing the Hive to BEEat the context window

## Inspiration

Agents have limited context window, how do we create extremely high quality and verifiable responses from the web?

## What it does

Create a "knowledge base" on some topic (basically a wiki, and literally a git repo), with hundreds of browser agents (spawned through an orchestrator) created rigorously cited and specific prs into the repo. Then we have review agents that ensures that only prs are merged after meeting strict adversarial standards.  From here a chat agent can navigate the repo to find specific information, and answer questions, with citations to specific docs where more information can be found.

## What's next for BeeWork
stanford roomates -> lovers -> cofounders

## Links
Slides: https://docs.google.com/presentation/d/1KGqUSn83BWOUU2tRIQxokh2dywbUY973HnNFKA0ZciM/edit?usp=sharing
Devpost: https://devpost.com/software/beework
GitHub: https://github.com/Alezander9/BeeWork
Website: https://beework.cc/
Demo: https://youtu.be/YL_5W60JScc


## Detected evidence (automated analysis)

Indexed codebase: 63 recognized source files, 187 KB.
- CSS (language) — detected in the code
- HTML (language) — detected in the code
- JavaScript (language) — detected in the code
- Python (language) — detected in the code
- React (technology) — detected in the code
- Tailwind CSS (technology) — detected in the code
- TypeScript (language) — detected in the code
- Anthropic (technology) — claimed on Devpost, not found in the code
- Google Gemini (technology) — claimed on Devpost, not found in the code
- OpenAI (technology) — claimed on Devpost, not found in the code
- Vercel (technology) — claimed on Devpost, not found in the code
- AI coding agent: Claude Code — evidence: config files committed to the repository
- AI coding agent: Codex — evidence: config files committed to the repository
- AI coding agent: Cursor — evidence: config files committed to the repository

## Codebase structure (from repository index)

### Files (83 of 83)

```
.env.example
.gitignore
.python-version
chat/AGENTS.MD
chat/opencode.json
chat/run_chat_agent.py
CLAUDE.md
frontend/.cursor/rules/convex_rules.mdc
frontend/.gitignore
frontend/.prettierrc
frontend/CLAUDE.md
frontend/components.json
frontend/convex/_generated/api.d.ts
frontend/convex/_generated/api.js
frontend/convex/_generated/dataModel.d.ts
frontend/convex/_generated/server.d.ts
frontend/convex/_generated/server.js
frontend/convex/chat.ts
frontend/convex/http.ts
frontend/convex/README.md
frontend/convex/schema.ts
frontend/convex/sessions.ts
frontend/convex/tsconfig.json
frontend/eslint.config.js
frontend/index.html
frontend/LICENSE.txt
frontend/package.json
frontend/src/App.tsx
frontend/src/components/ChatOverlay.tsx
frontend/src/components/HoneycombBg.tsx
frontend/src/components/SettingsDialog.tsx
frontend/src/components/ui/button.tsx
frontend/src/components/ui/card.tsx
frontend/src/components/ui/dialog.tsx
frontend/src/components/ui/input.tsx
frontend/src/components/ui/label.tsx
frontend/src/index.css
frontend/src/lib/api.ts
frontend/src/lib/auth.ts
frontend/src/lib/utils.ts
frontend/src/main.tsx
frontend/src/pages/Buy.tsx
frontend/src/pages/Home.tsx
frontend/src/pages/NewSessionView.tsx
frontend/src/pages/Sessions.tsx
frontend/src/vite-env.d.ts
frontend/tsconfig.app.json
frontend/tsconfig.json
frontend/tsconfig.node.json
frontend/vercel.json
frontend/vite.config.ts
main.py
orchestrator/AGENTS.MD
orchestrator/opencode.json
orchestrator/run_orchestrator_agent.py
orchestrator/tools/create_research_task.py
orchestrator/tools/search_web.py
pyproject.toml
README.MD
researcher/AGENTS.MD
researcher/opencode.json
researcher/run_researcher_agent.py
researcher/start_browser_agent.py
reviewer/AGENTS.MD
reviewer/opencode.json
reviewer/run_reviewer_agent.py
server/main.py
shared/__init__.py
shared/full_pipeline_update.md
shared/full_pipeline.py
shared/project_documents/california_rng_deep.md
shared/project_documents/california_rng.md
shared/project_documents/gemini_vc_project.md
shared/project_documents/med_example.md
shared/project_documents/small_test.md
shared/project_documents/tiny_test_with_sites.md
shared/project_documents/tiny_test.md
shared/project_documents/treehacks_stalking.md
shared/query_laminar.py
shared/server.py
shared/telemetry.py
shared/tracing.py
uv.lock
```

### Dependencies

- frontend/package.json: @convex-dev/eslint-plugin@^1.1.1, @eslint/js@^9.39.2, @fontsource-variable/outfit@^5.2.8, @tailwindcss/vite@^4.1.18, @types/node@^24.10.11, @types/react@^19.2.13, @types/react-dom@^19.2.3, @vitejs/plugin-react@^5.1.3, class-variance-authority@^0.7.1, clsx@^2.1.1, convex@^1.31.7, eslint@^9.39.2, eslint-plugin-react-hooks@^7.0.1, eslint-plugin-react-refresh@^0.5.0, globals@^17.3.0, lucide-react@^0.564.0, motion@^12.34.0, npm-run-all2@^8.0.4, prettier@^3.8.1, radix-ui@^1.4.3, react@^19.2.4, react-dom@^19.2.4, react-router-dom@^7.13.0, shadcn@^3.8.4, tailwind-merge@^3.4.0, tailwindcss@^4.1.18, tw-animate-css@^1.4.0, typescript@~5.9.3, typescript-eslint@^8.54.0, vite@^7.3.1
- pyproject.toml: fastapi[standard], lmnr@>=0.7.41, modal@>=1.3.3, python-dotenv@>=1.2.1

### Recent commits (newest first)

- Add splash image to README
- Update README with project details and links
- gem
- done
- Merge branch 'main' of https://github.com/Alezander9/BeeWork
- treehacks stalking
- trigger redeploy
- Merge branch 'main' of https://github.com/Alezander9/BeeWork
- big rng deep repo
- hide old sessions
- set default to med example
- fix vercel 404 refresh error
- add saved prompts to frontend
- add three chat system and multiple convex log endpoints
- add links to home page
- fix gitignored important files
- add chat to frontend
- finish new session view
- change citation format
- Merge branch 'main' of https://github.com/Alezander9/BeeWork

## Key source files (fetched from GitHub, selected and truncated for size)

### CLAUDE.md

```markdown
# CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

## Project Overview

BeeWork is an autonomous multi-agent system for building and maintaining knowledge bases. Built for TreeHacks 2026. Specialized agents research topics via web browsing, write content with citations, review PRs for quality, and answer questions over the knowledge base.

## Tech Stack

- **Python 3.12** with **UV** package manager
- **Modal** for serverless sandbox execution (each agent runs in an isolated container)
- **OpenCode** as the AI coding agent framework (provides bash/edit/write tools inside sandboxes)
- **Google Gemini 3 Flash Preview** as the primary LLM (configured in each agent's `opencode.json`)
- **Laminar** (`lmnr`) for observability/tracing of LLM calls
- **Browser-Use API** for automated web research
- **Parallel.ai** for web search

## Commands

```bash
# Install dependencies
uv sync

# Run the orchestrator (creates KB repo, generates research tasks)
uv run python orchestrator/run_orchestrator_agent.py <repo_name>

# Run a researcher agent (browser research + KB editing)
uv run python researcher/run_research_agent.py --topic "..." --prompt "..." --file-path "..." --websites "..." --repo "owner/repo"

# Run the reviewer agent (PR quality gate)
uv run python reviewer/run_sandbox_agent.py --repo "owner/repo" --pr <pr_number>

# Run the chat agent (interactive Q&A over knowledge base)
uv run python chat/run_chat_agent.py --repo "owner/repo"
```

## Architecture

### Agent Pipeline Flow

```
Orchestrator → [Research Tasks] → Researcher(s) (parallel) → PRs → Reviewer → Merged KB
                                                                                    ↓
                                                                              Chat Agent (Q&A)
```

### Four Specialized Agents

Each agent lives in its own directory with three key files:
- `run_*.py` — Python entry point that creates a Modal sandbox and runs the agent
- `AGENTS.MD` — Natural language instructions the OpenCode agent follows
- `opencode.json` — Model selection, tool permissions, and agent configuration

| Agent | Directory | Execution | Entry Point |
|-------|-----------|-----------|-------------|
| Orchestrator | `orchestrator/` | Modal (`test-opencode`) | `run_orchestrator_agent.py` |
| Researcher | `researcher/` | Modal (`beework-worker`) | `run_research_agent.py` |
| Reviewer | `reviewer/` | Modal (`beework-reviewer`) | `run_sandbox_agent.py` |
| Chat | `chat/` | Local (subprocess) | `run_chat_agent.py` |

### Execution Pattern (pipeline agents: orchestrator, researcher, reviewer)

1. Load env vars from `.env` at project root
2. Build a Modal container image (Debian + OpenCode + gh CLI + agent code)
3. Create Modal sandbox with secrets injected
4. Clone the knowledge base GitHub repo inside the sandbox
5. Run `opencode run` with a task-specific prompt (PTY required — OpenCode hangs without it)
6. Observe/trace output v
[truncated — 2299 more characters]
```

### chat/AGENTS.MD

```markdown
# Instructions

You are a knowledgebase Q&A chatbot. You are having an interactive conversation with a user.

## Environment

The knowledgebase repo is cloned at `knowledgebase/` in your working directory. It contains markdown files organized by topic.

## Task

1. Read the user's question (and any prior conversation context provided in the prompt).
2. Search the knowledgebase files to find relevant information. Start with the directory structure, then read files that are most likely to contain the answer.
3. Answer the question clearly and concisely.
4. If the knowledgebase contains relevant information, cite which files it came from.
5. If the knowledgebase does not cover the topic, you may use your own knowledge to answer, but state clearly that the answer is not from the knowledgebase. Always prefer cited information over your own knowledge.

## Constraints

- Do NOT modify any files. This is a read-only task.
- Prefer knowledgebase information over your own knowledge when both are available.
- Keep answers concise. Do not repeat the question back.
- When conversation history is provided, use it for context but focus on the current question.

```

### pyproject.toml

```
[project]
name = "beework"
version = "0.1.0"
description = "Add your description here"
readme = "README.md"
requires-python = ">=3.12"
dependencies = [
    "fastapi[standard]",
    "lmnr>=0.7.41",
    "modal>=1.3.3",
    "python-dotenv>=1.2.1",
]

```

### frontend/package.json

```
{
  "name": "beework",
  "private": true,
  "version": "0.0.0",
  "type": "module",
  "scripts": {
    "dev": "npm-run-all --parallel dev:frontend dev:backend",
    "dev:frontend": "vite --open",
    "dev:backend": "convex dev",
    "predev": "convex dev --until-success && convex dashboard",
    "build": "tsc -b && vite build",
    "lint": "tsc && eslint .  --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
    "preview": "vite preview"
  },
  "dependencies": {
    "@fontsource-variable/outfit": "^5.2.8",
    "class-variance-authority": "^0.7.1",
    "clsx": "^2.1.1",
    "convex": "^1.31.7",
    "lucide-react": "^0.564.0",
    "motion": "^12.34.0",
    "radix-ui": "^1.4.3",
    "react": "^19.2.4",
    "react-dom": "^19.2.4",
    "react-router-dom": "^7.13.0",
    "tailwind-merge": "^3.4.0"
  },
  "devDependencies": {
    "@convex-dev/eslint-plugin": "^1.1.1",
    "@eslint/js": "^9.39.2",
    "@tailwindcss/vite": "^4.1.18",
    "@types/node": "^24.10.11",
    "@types/react": "^19.2.13",
    "@types/react-dom": "^19.2.3",
    "@vitejs/plugin-react": "^5.1.3",
    "eslint": "^9.39.2",
    "eslint-plugin-react-hooks": "^7.0.1",
    "eslint-plugin-react-refresh": "^0.5.0",
    "globals": "^17.3.0",
    "npm-run-all2": "^8.0.4",
    "prettier": "^3.8.1",
    "shadcn": "^3.8.4",
    "tailwindcss": "^4.1.18",
    "tw-animate-css": "^1.4.0",
    "typescript": "~5.9.3",
    "typescript-eslint": "^8.54.0",
    "vite": "^7.3.1"
  }
}

```

### main.py

```python
def main():
    print("Hello from beework!")


if __name__ == "__main__":
    main()

```

### shared/server.py

```python
"""Local FastAPI server -- receives pipeline trigger requests via cloudflared.

Run:
    uv run uvicorn shared.server:app --host 0.0.0.0 --port 8111
"""

import threading
import time
import uuid

from fastapi import FastAPI
from pydantic import BaseModel

app = FastAPI(title="BeeWork Local Server")


class PipelineRequest(BaseModel):
    repo: str
    project: str
    max_parallel: int = 5
    start_from: str = "orchestrator"


class PipelineResponse(BaseModel):
    run_id: str
    status: str


def _run_pipeline_dummy(run_id: str, req: PipelineRequest) -> None:
    """Placeholder -- will call real full_pipeline.run_pipeline() later."""
    print(f"[server] Pipeline started: run_id={run_id} repo={req.repo}")
    time.sleep(2)
    print(f"[server] Pipeline finished: run_id={run_id}")


@app.post("/start-pipeline", response_model=PipelineResponse)
def start_pipeline(req: PipelineRequest) -> PipelineResponse:
    run_id = uuid.uuid4().hex[:12]
    threading.Thread(target=_run_pipeline_dummy, args=(run_id, req), daemon=True).start()
    return PipelineResponse(run_id=run_id, status="started")


@app.get("/health")
def health():
    return {"ok": True}

```

### server/main.py

```python
"""BeeWork local API server -- receives commands from Convex via cloudflared tunnel."""

import os
import subprocess
import sys
from pathlib import Path

from dotenv import load_dotenv
from fastapi import FastAPI, Header, HTTPException
from fastapi.middleware.cors import CORSMiddleware
from pydantic import BaseModel

PROJECT_ROOT = Path(__file__).resolve().parents[1]
load_dotenv(PROJECT_ROOT / ".env")

SECRET_KEY = os.environ["BEEWORK_SECRET_KEY"]

app = FastAPI()

app.add_middleware(
    CORSMiddleware,
    allow_origins=["*"],
    allow_methods=["*"],
    allow_headers=["*"],
)


class StartRequest(BaseModel):
    sessionId: str
    repo: str
    researchWorkers: int = 5
    reviewWorkers: int = 2
    project: str = "shared/project_documents/tiny_test.md"
    convexSiteUrl: str = ""


@app.post("/start")
async def start_pipeline(body: StartRequest, x_api_key: str = Header()):
    if x_api_key != SECRET_KEY:
        raise HTTPException(status_code=401, detail="invalid key")

    cmd = [
        sys.executable, str(PROJECT_ROOT / "shared" / "full_pipeline.py"),
        "--repo", body.repo,
        "--project", body.project,
        "--research-workers", str(body.researchWorkers),
        "--review-workers", str(body.reviewWorkers),
        "--session-id", body.sessionId,
    ]
    if body.convexSiteUrl:
        cmd += ["--convex-site-url", body.convexSiteUrl]
    subprocess.Popen(cmd, cwd=str(PROJECT_ROOT))
    print(f"[server] launched pipeline for session {body.sessionId}")

    return {"ok": True}

```

### frontend/src/main.tsx

```typescript
import { StrictMode } from "react";
import { createRoot } from "react-dom/client";
import { BrowserRouter } from "react-router-dom";
import { ConvexProvider, ConvexReactClient } from "convex/react";
import "./index.css";
import App from "./App.tsx";

const convex = new ConvexReactClient(import.meta.env.VITE_CONVEX_URL as string);

createRoot(document.getElementById("root")!).render(
  <StrictMode>
    <BrowserRouter>
      <ConvexProvider client={convex}>
        <App />
      </ConvexProvider>
    </BrowserRouter>
  </StrictMode>,
);

```

### frontend/src/App.tsx

```typescript
import { Routes, Route } from "react-router-dom";
import HoneycombBg from "@/components/HoneycombBg";
import Home from "@/pages/Home";
import Sessions from "@/pages/Sessions";
import NewSessionView from "@/pages/NewSessionView";
import Buy from "@/pages/Buy";

export default function App() {
  return (
    <>
      <HoneycombBg />
      <Routes>
        <Route path="/" element={<Home />} />
        <Route path="/sessions" element={<Sessions />} />
        <Route path="/sessions/:id" element={<NewSessionView />} />
        <Route path="/buy" element={<Buy />} />
      </Routes>
    </>
  );
}

```

### frontend/convex/_generated/server.js

```javascript
/* eslint-disable */
/**
 * Generated utilities for implementing server-side Convex query and mutation functions.
 *
 * THIS CODE IS AUTOMATICALLY GENERATED.
 *
 * To regenerate, run `npx convex dev`.
 * @module
 */

import {
  actionGeneric,
  httpActionGeneric,
  queryGeneric,
  mutationGeneric,
  internalActionGeneric,
  internalMutationGeneric,
  internalQueryGeneric,
} from "convex/server";

/**
 * Define a query in this Convex app's public API.
 *
 * This function will be allowed to read your Convex database and will be accessible from the client.
 *
 * @param func - The query function. It receives a {@link QueryCtx} as its first argument.
 * @returns The wrapped query. Include this as an `export` to name it and make it accessible.
 */
export const query = queryGeneric;

/**
 * Define a query that is only accessible from other Convex functions (but not from the client).
 *
 * This function will be allowed to read from your Convex database. It will not be accessible from the client.
 *
 * @param func - The query function. It receives a {@link QueryCtx} as its first argument.
 * @returns The wrapped query. Include this as an `export` to name it and make it accessible.
 */
export const internalQuery = internalQueryGeneric;

/**
 * Define a mutation in this Convex app's public API.
 *
 * This function will be allowed to modify your Convex database and will be accessible from the client.
 *
 * @param func - The mutation function. It receives a {@link MutationCtx} as its first argument.
 * @returns The wrapped mutation. Include this as an `export` to name it and make it accessible.
 */
export const mutation = mutationGeneric;

/**
 * Define a mutation that is only accessible from other Convex functions (but not from the client).
 *
 * This function will be allowed to modify your Convex database. It will not be accessible from the client.
 *
 * @param func - The mutation function. It receives a {@link MutationCtx} as its first argument.
 * @returns The wrapped mutation. Include this as an `export` to name it and make it accessible.
 */
export const internalMutation = internalMutationGeneric;

/**
 * Define an action in this Convex app's public API.
 *
 * An action is a function which can execute any JavaScript code, including non-deterministic
 * code and code with side-effects, like calling third-party services.
 * They can be run in Convex's JavaScript environment or in Node.js using the "use node" directive.
 * They can interact with the database indirectly by calling queries and mutations using the {@link ActionCtx}.
 *
 * @param func - The action. It receives an {@link ActionCtx} as its first argument.
 * @returns The wrapped action. Include this as an `export` to name it and make it accessible.
 */
export const action = actionGeneric;

/**
 * Define an action that is only accessible from other Convex functions (but not from the client).
 *
 * @param func - The function. It receives an {@link ActionCtx} as its first argument.
 * @returns The wrapped function. Include this as an `export` to name it and make it accessible.
 */
export const internalAction = internalActionGeneric;

/**
 * Define an HTTP action.
 *
 * The wrapped function will be used to respond to HTTP requests received
 * by a Convex deployment if the requests matches the path and method where
 * this action is routed. Be sure to route your httpAction in `convex/http.js`.
 *
 * @param func - The function. It receives an {@link ActionCtx} as its first argument
 * and a Fetch API `Request` object as its second.
 * @returns The wrapped function. Import this function from `convex/http.js` and route it to hook it up.
 */
export const httpAction = httpActionGeneric;

```

[52 more indexed source files omitted to keep this export small. The full file list is in the Codebase structure section above.]