# AI use cases for Trueforge (truefoundry/trueforge)

Repo: [truefoundry/trueforge](https://github.com/truefoundry/trueforge) | Use cases: 4 | Page: https://dedupedai.com/use-cases/truefoundry-trueforge/

TrueForge is an open-source TypeScript agent harness that runs the agent loop for you, covering model calls, MCP tools, skills, sandboxing, approvals, context management, and session state.

This file holds every use case of this repo. Each one starts with a "## " heading and ends with its URL.

- Run a local agent chat with your own models and tools: https://dedupedai.com/use-cases/truefoundry-trueforge/run-local-agent-chat/
- Script agent sessions with the TrueForge TypeScript SDK: https://dedupedai.com/use-cases/truefoundry-trueforge/automate-agent-sessions-with-sdk/
- Run a saved agent on a schedule and review each session: https://dedupedai.com/use-cases/truefoundry-trueforge/schedule-saved-agent-runs/
- Deploy a shared hosted harness for a team: https://dedupedai.com/use-cases/truefoundry-trueforge/deploy-hosted-team-harness/

## How to run a local agent chat with your own models and tools with Trueforge

Repo: [truefoundry/trueforge](https://github.com/truefoundry/trueforge) | Difficulty: Beginner | Time: 15 minutes | Basis: From the README

Start TrueForge on one machine and chat with an agent that uses MCP tools and skills.

**Who it is for:** A developer who wants to try an agent on their own machine before deciding on a team setup.

**The problem:** Building an agent loop with streaming, session storage, tool servers, approvals, and a UI takes significant effort before any real work can start.

**The outcome:** A working local agent chat connected to a chosen model, with MCP tools and skills available to the agent.

### Steps

1. Run `npx @truefoundry/trueforge@latest` in a terminal.
2. Open the bundled chat UI and connect a model from the catalog or an OpenAI-compatible endpoint.
3. Add MCP servers and skills from the Initial Setup catalogs.
4. Create an agent that selects those resources and enable tool approval.
5. Keep the instance on localhost, because local mode has no login by default and stores data in SQLite.

### Prompt to paste into your agent

```text
Using the truefoundry/trueforge repo, start TrueForge locally with `npx @truefoundry/trueforge@latest`, connect the model <model-provider>, and create an agent that uses one MCP server named <mcp-server>. Report the agent's name and the URL of the chat UI. Verify that the agent answers a test prompt and that the session appears in Sessions.
```

### Caveat

The README says local mode is for your machine only and should stay on localhost, so do not expose it to the internet.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/truefoundry-trueforge/run-local-agent-chat/

## How to script agent sessions with the TrueForge TypeScript SDK with Trueforge

Repo: [truefoundry/trueforge](https://github.com/truefoundry/trueforge) | Difficulty: Intermediate | Time: 45 minutes | Basis: From the README

Drive agent sessions and turns from your own TypeScript code using the HTTP API and SDK.

**Who it is for:** A developer who wants to call an agent from a script, service, or pipeline instead of the chat UI.

**The problem:** Teams need agent runs that other code can start, track, and read back, not only interactive chat.

**The outcome:** A script that creates a session, sends turns, reads events, and produces a result that can be inspected later in Sessions.

### Steps

1. Start TrueForge with `npx @truefoundry/trueforge@latest`.
2. Install the client with `npm install @truefoundry/trueforge-sdk` in your project. (inferred, check the README)
3. Create a session with the SDK and send a turn that asks the agent for <task>.
4. Read the streamed events and save the final answer to <output-file>.
5. Open Sessions in the UI and check that the turns, tool calls, and token counts match your script's output.

### Prompt to paste into your agent

```text
In the truefoundry/trueforge repo, use the TypeScript SDK @truefoundry/trueforge-sdk to create a session against a running local TrueForge instance and send one turn asking for <task>. Output the final answer and the session ID. Verify that the same session appears in the Sessions view with its turns and tool calls.
```

### Caveat

The README says maintainers regenerate the SDK after merge, so check the API Reference for current paths before you hard-code calls.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/truefoundry-trueforge/automate-agent-sessions-with-sdk/

## How to run a saved agent on a schedule and review each session with Trueforge

Repo: [truefoundry/trueforge](https://github.com/truefoundry/trueforge) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Save an agent once, run it on a recurring cadence without you present, and audit each run.

**Who it is for:** An operations or support engineer who needs the same agent task to run repeatedly, such as a daily check.

**The problem:** Repeating agent work by hand is slow, and unattended runs are hard to audit without a record of what the agent did.

**The outcome:** A saved agent that runs on a schedule, with each run's turns, tool calls, subagents, tokens, and timing available for review.

### Steps

1. Create and save an agent that selects the models, MCP tools, and skills it needs.
2. Open Schedules and set the saved agent to run on a recurring cadence.
3. Wait for one scheduled run to finish.
4. Open Sessions and review that run's turns, tool calls, subagents, tokens, and timing.
5. Adjust which tools need approval so that unattended runs behave as you expect.

### Prompt to paste into your agent

```text
Using the truefoundry/trueforge repo, take the saved agent named <agent-name> and set a schedule that runs it every <cadence>. After one scheduled run, report its session ID and tool call count from Sessions. Verify that the run completed without a pending approval.
```

### Caveat

The README does not describe how approvals behave during scheduled runs, so test one run before relying on it unattended.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/truefoundry-trueforge/schedule-saved-agent-runs/

## How to deploy a shared hosted harness for a team with Trueforge

Repo: [truefoundry/trueforge](https://github.com/truefoundry/trueforge) | Difficulty: Advanced | Time: 2 hours | Basis: From the README

Run TrueForge in hosted mode with Postgres and Redis so a team shares one agent setup.

**Who it is for:** A platform engineer who must give several teammates the same models, tools, and sandbox behind a login.

**The problem:** Local mode is single-user and has no login by default, so a team needs a shared, multi-replica deployment.

**The outcome:** A hosted TrueForge deployment with shared catalogs, optional OIDC login, and a sandbox available to agents.

### Steps

1. Choose hosted mode, which uses Postgres and Redis for storage.
2. Deploy with Docker Compose, Helm, or Railway by following the Quickstart guide.
3. Connect shared models, MCP servers, skills, and the sandbox in Initial Setup.
4. Enable optional OIDC login from the Setup Login guide before inviting teammates.
5. Create one shared agent and confirm a teammate can run it and see the session in Sessions.

### Prompt to paste into your agent

```text
In the truefoundry/trueforge repo, deploy hosted mode using <deployment-method> (Docker Compose, Helm, or Railway) following the Quickstart, then connect one model and one MCP server. Report the deployment URL and confirm that a login is required. Verify that a shared agent runs successfully for a second user.
```

### Caveat

The README gives no setup steps for Helm, Docker Compose, or Railway beyond naming them, so follow the linked Quickstart for exact instructions.

Risk, credentials: Shared MCP header auth, OAuth tokens, and model keys are stored in the harness, so limit who can view or change these connections.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/truefoundry-trueforge/deploy-hosted-team-harness/
