PromptisePromptise
Docs
GitHub
Promptise - AI Framework LogoPromptise

The foundation layer for agentic intelligence. Build, secure and operate autonomous AI systems with Promptise Foundry.

pip install promptise

[01] Foundry

  • MCPcast
  • The Promptise Agent
  • Reasoning Engine
  • MCP
  • Agent Runtime
  • Prompt Engineering
  • Execution Engine
  • Agent Identity

[02] Resources

  • Documentation
  • GitHub
  • Guides
  • Learning Paths
  • Questions

[03] Company

  • About
  • Terms of Service
  • Privacy Policy
  • Cookie Policy
  • Subprocessors

© 2026 Promptise by Manser Ventures. All rights reserved.

Open source · Python

← Guides> Topic

Building AI agents in Python

An AI agent is a program that gives a language model a goal, a set of tools and a loop: the model decides on a step, the program runs it, and the result goes back to the model until the task is done. The model is only one part. The rest is ordinary software that decides what the model sees, which tools it may call, when to stop and what happens when something fails.

These guides build that software in Python, starting with a working agent and then covering each piece in turn: the harness around the model, the system prompt, choosing a model for tool calling, keeping an agent's setup in a YAML file, and streaming its answers to a web client. Each guide explains the idea first and then shows runnable code with Promptise Foundry. Start with the first guide if you are new to agents; the others can be read in any order.

[n.01/02]> 7 guides, in order
  1. 01What Is an AI Agent? Definition, How It Works, ExamplesWhat an AI agent is: a model that calls tools in a loop until a goal is met. How the loop works, a real example, agents vs chatbots and workflows, FAQs.Beginner · 7 minOct 18, 2026
  2. 02How to Build an AI Agent in Python (2026 Guide)Build an AI agent in Python step by step: write the tool loop, serve tools over MCP, add model fallback, approvals and limits. Runnable code, real output.Beginner · 20 minOct 18, 2026
  3. 03What Is an Agent Harness? Parts and How to Build OneWhat an agent harness is and how to build one: the tool loop, context compaction, token budgets, loop guards and verification, with runnable code.Intermediate · 18 minOct 18, 2026
  4. 04System Prompt Best Practices for AI Agents in PythonBuild agent system prompts from reusable blocks, switch them by conversation phase, and test them like code. Real Python runs, honest limits.Intermediate · 24 minOct 11, 2026
  5. 05Best LLM for AI Agents: Test and Switch Models in PythonFind the best LLM for your AI agent with a tool-calling eval, then switch between OpenAI, Anthropic, Azure, Bedrock, Gemini and Ollama in one line.Intermediate · 22 minOct 11, 2026
  6. 06AI Agent YAML: Define and Run an Agent From a Config FileDefine an AI agent in a YAML file: model, instructions and MCP servers. Validate it, run it from the CLI or Python, keep secrets out, review it in Git.Intermediate · 18 minOct 11, 2026
  7. 07Streaming LLM Responses with FastAPI: Tokens and Tool CallsStream an AI agent's tool calls and answer from FastAPI to a web page with Server-Sent Events, with cancellation, errors and an EventSource page.Intermediate · 14 minOct 11, 2026
[n.02/02]> go further

In the documentation

  • Quickstartdocs ↗
  • Building agentsdocs ↗
  • Configurationdocs ↗
  • Streamingdocs ↗

Other topics

  • Models and providers→
  • Tools and the Model Context Protocol (MCP)→
  • Memory, context and RAG→
  • Agent reasoning patterns→
  • Multi-agent systems→
  • Guardrails and security→
  • Human approvals (human-in-the-loop)→
  • Observability and debugging→
  • Cost control and rate limits→
  • Testing and evals→
  • Runtime, triggers and deployment→
  • Frameworks and comparisons→

Build it with Promptise Foundry.

The code in these guides runs on Promptise Foundry, an open-source Python framework for AI agents and MCP servers.

QuickstartAll guides