langchain-samples/Persistent-Agent
AI EngineeringA Slack-hosted, team-shared AI agent with per-user memory, goals, scheduled playbooks, and tool integrations.
This project ships 7 agent skillsSkill list and install →What it is
Persistent Agent is a template for deploying one always-on AI assistant into a Slack workspace for a whole team. It is built on LangChain's Managed Deep Agents runtime rather than on a self-hosted agent loop, so the repository supplies the agent instructions, skills, channel wiring, and tool connection code while LangSmith handles deployment.
Each person gets private memory, goals, schedules, connected app accounts, and browser sessions, but everyone shares a single deployment and one Slack bot. Background jobs cover recurring tasks, research done by subagents, a nightly "dreaming" job that consolidates memory, and a watch mode that reads channel messages and speaks only when useful. External capabilities come through LangSmith's Tool Gateway, with built-in integrations such as Gmail, GitHub, Slack, Linear, Google Drive, and Salesforce.
Quickstart
Prerequisites: uv, a LangSmith workspace on a Plus or Enterprise plan, a model key from Anthropic or OpenAI (or the optional LLM Gateway), and a Slack workspace where you can install apps.
- Clone the repository, install dependencies, and copy the environment template:
git clone https://github.com/langchain-samples/Persistent-Agent.git
cd Persistent-Agent
uv sync
cp .env.example .env
- Create a LangSmith personal access token and note the target workspace ID, then connect the apps you want in LangSmith Tools and copy the tool kit's MCP URL. The three-part walkthrough covers workspace and key setup and tool kit creation.
- Fill in
.env:
LANGSMITH_API_KEY=<your-langsmith-personal-access-token>
LANGSMITH_WORKSPACE_ID=<your-workspace-id>
TOOLS_MCP_URL=<your-tool-kit-mcp-url>
AGENT_MODEL=anthropic:claude-opus-5-5
ANTHROPIC_API_KEY=<your-anthropic-api-key>
- Deploy from the repository root:
uv run mda deploy
Approve the Slack app when the authorization link appears, return to the terminal, and press Enter. After the deployment reports ready, DM the bot hi and complete any per-user app connections. A successful first test is asking the bot to use the LangChain documentation tool and confirming a tool call in the run trace; the full sequence is in Deploy and connect Slack.
Configuration and usage
Models are selected with a single AGENT_MODEL line: anthropic:claude-opus-5-5 with an Anthropic key, openai:gpt-6.1-sol with an OpenAI key, or a langsmith: route through the optional LLM Gateway. The agent does not fall back automatically when a key is missing. See model options.
Typical requests include "Send me a morning brief," "Every Friday at 4, summarize what I shipped," "Let me know when the release PR is approved," and "Research our top three competitors' pricing." The agent asks for confirmation before booking, buying, sending, or deleting. !clear wipes a user's memory and cancels their schedules. Behavior is customized by editing instructions.md and the skills/ folder, then redeploying.
Constraints
- The quickstart assumes a paid LangSmith plan; some features such as the Tools page and workspace tool kits depend on plan, region, and admin access.
- Hosted runtime, tool gateway, and model calls are all external services, so setup requires several separate credentials. Tools execute with each user's own account access, and browser/connect links are delivered only in that person's DM.
- Built-in integrations must be connected before their tools can be selected in a kit, and a kit with no tools gives the agent no app capabilities.
- If the shell already exports a
LANGSMITH_API_KEY, deployment may pick it up instead of the.envvalue; the README documents anenv -u ...workaround (details). - The project is MIT-licensed; the underlying Deep Agents runtime is a separate open-source project.
HotRepo's take
Persistent Agent entered HotRepo's new-project list on 2026-11-26 with 6 stars gained in roughly one hour, reaching 106 stars and 6 forks, with no recorded all-language daily ranking. That is too short a window to read as a trend; what stands out instead is the design choice of shipping a thin template (instructions, seven skills, Slack channel, MCP tool bridge) on top of a managed agent service. It is most useful to teams already in the LangSmith ecosystem who want a shared Slack assistant with per-user memory, not to people looking for a self-contained agent they can run locally without a platform account.
Written by AI from the project's public information and HotRepo's records, updated . The project's own docs are the source of truth.