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
14 changes: 11 additions & 3 deletions .spellcheck-en-custom.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
Akers
Augumented
acp
ACP
Arize
ai
Akers
Anthropic
api
Arize
Augumented
auth
beeai
BeeAI's
BJ
Expand All @@ -19,6 +22,7 @@ config
configs
Coreutils
csv
customizable
dataframe
dataset
datetime
Expand All @@ -39,15 +43,18 @@ groq
Hargrave
Homebrew
Huggingface
hostable
ibm
ImageMagick
inferencing
InstructLab
integrations
ipynb
ipython
jupyter
Jupyter
Kaggle
Kubernetes
Langchain
localhost
LLM
Expand Down Expand Up @@ -118,6 +125,7 @@ url
uv
verifiers
virtualenv
watsonx
workspaces
WSL
Vectorization
Expand Down
Empty file removed docs/opentech/agentstack/README.md
Empty file.
66 changes: 66 additions & 0 deletions docs/opentech/agentstack/overview/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
---
title: Introduction to Agent Stack
description: Introduction to Agent Stack
logo: images/BeeAI-Logo-White.png
---

# Introduction to Agent Stack

In this demo. You'll master the fundamental components of **Agent Stack** by building and running a Conference Prep Agent that helps field marketing teams prepare for conference season.

Through hands-on exercises, you'll learn how to create intelligent agents with real-world applications.

<hr>

## 🎯 Scenario

The Field Marketing Lead has asked you to help prepare their team for conference season. You'll create a **Conference Prep Agent** that intelligently combines multiple information sources to provide comprehensive conference preparation materials.

Your agent will integrate three powerful tools:

1. **Web Search** – Collect relevant news and up-to-date information about attendees, speakers, and industry trends
2. **Wikipedia Tool** – Provide company history and background details on organizations and key people
3. **Internal Knowledge Base** – Access the team's internal notes and artifacts for context-specific information

<hr>

## 📚 What You'll Learn

Through interactive coding exercises, you'll gain hands-on experience with:

### Agent Stack

- **Serving agents** – Run an agent from source and see it automatically register with Agent Stack
- **UI forms** – Use a form as input to the agent with the Agent Stack UI
- **Monitoring** – Monitor and debug agents with built-in logging and tracing capabilities

### Agent Core Components

- **System Prompts** – Learn the foundation of agent behavior by crafting effective prompts that guide your agent's responses
- **RequirementAgent** – Explore BeeAI Framework's powerful agent implementation that provides fine-grained control over agent behavior
- **LLM Providers** – Work with both local and hosted model options to understand deployment flexibility

### Advanced Features

- **Memory Systems** – Implement conversation context to maintain coherent, contextual interactions across sessions
- **Tools Integration** – Extend agent capabilities by integrating external APIs and data sources
- **Conditional Requirements** – Enforce business logic and rules to ensure compliance and consistency

<hr>

## Workshop Structure

To ensure a smooth experience, follow the steps in this order:

1. ✅ [Prework](../pre-work/README.md) – Install dependencies and gather API keys
2. 🔧 [Setup](../setup/README.md) – Get the code and environment ready
4. 🤖 [Run the agent](../run/README.md) – Assemble and run your agent

<hr>

## Learn more about Agent Stack

- 📚 **Agent Stack documentation**: [https://agentstack.beeai.dev/introduction/welcome](https://agentstack.beeai.dev/introduction/welcome)
- 🧠 **GitHub repository**: [https://github.com/i-am-bee/agentstack](https://github.com/i-am-bee/agentstack)

Ready to build your first intelligent agent? Let's dive in! 🐝
57 changes: 57 additions & 0 deletions docs/opentech/agentstack/pre-work/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
---
title: Prework
description: Prework Instructions
logo: images/BeeAI-Logo-White.png
---

# Agent Stack: Prework Instructions

Welcome to the Introduction to Agent Stack.
Please complete the following setup steps **before** the workshop.

---

## Python Environment Manager

### `uv` (Recommended)

We recommend using [`uv`](https://github.com/astral-sh/uv) as your Python package and environment manager.

- If you’re unfamiliar with `uv`, refer to the [uv installation guide](https://github.com/astral-sh/uv#installation)
- `uv` is a fast and modern alternative to pip and virtualenv, fully compatible with both

---

## Local Model

### Install Ollama

!!! note
To run the Granite model locally, we recommend having at least **16GB of RAM** for optimal performance.

To run models locally on your machine:

1. Download and install Ollama: [https://ollama.com/download](https://ollama.com/download)
2. Run or pull the Granite model:

```bash
ollama pull granite4:micro-h
```

or

```bash
ollama run granite4:micro-h
```

### Granite model links

- Ollama models: [Granite 4](https://ollama.com/library/granite4)
- Ollama models: [Granite 3.3](https://ollama.com/library/granite3.3)
- Granite docs: [Granite](https://www.ibm.com/granite/docs/models/granite)

---

## You're Ready

Once you've completed these steps, you're ready to setup the project.
113 changes: 113 additions & 0 deletions docs/opentech/agentstack/run/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
---
title: Agent Stack
description: Run the Agent Stack and use your agents in the UI
logo: images/BeeAI-Logo-White.png
---

# Interact with your agents using Agent Stack

Agent Stack is an open, self-hostable infrastructure for deploying AI agents built with any framework. A Linux Foundation project built on the Agent2Agent Protocol (A2A), Agent Stack gives you everything needed to move agents from local development to shared production environments—without vendor lock-in.

## What Agent Stack provides

Agent Stack provides everything you need to deploy and operate agents in production:

* Self-hostable server to run your agents
* Web UI for testing and sharing deployed agents
* CLI for deploying and managing agents
* Runtime services your agents can access:

* LLM Service — Switch between 15+ providers (Anthropic, OpenAI, watsonx.ai, Ollama) without code changes
* Embeddings & vector search for RAG and semantic search
* File storage — S3-compatible uploads/downloads
* Document text extraction via Docling
* External integrations via MCP protocol (APIs, Slack, Google Drive, etc.) with OAuth
* Secrets management for API keys and credentials
* SDK (`agentstack-sdk`) for standardized A2A service requests
* HELM charts for Kubernetes deployments with customizable storage, databases, and auth

## Lab

### 1. Install Agent Stack

Install Agent Stack using the [installation instructions in the documentation](https://agentstack.beeai.dev/introduction/quickstart#installation).

#### Follow the "One-Line Install"

To install a specific version of Agent Stack, set the `AGENTSTACK_VERSION` environment variable before running the install script. For example:

```bash
sh -c "$(AGENTSTACK_VERSION=0.4.1 curl -LsSf https://raw.githubusercontent.com/i-am-bee/agentstack/HEAD/install.sh)"
```

### 2. Start the Agent Stack (optionally with Phoenix and Docling enabled)

Agent Stack includes OpenTelemetry instrumentation to collect traces and metrics. Telemetry data helps with performance monitoring, error tracking, usage analytics, and debugging agent interactions.

> Important License Notice: Phoenix is disabled by default in Agent Stack. When you enable Phoenix, be aware that Arize Phoenix is licensed under the Elastic License v2 (ELv2), which has specific terms regarding commercial use and distribution. By enabling Phoenix, you acknowledge that you are responsible for ensuring compliance with the ELv2 license terms for your specific use case. Please review the Phoenix license before enabling this feature in production environments.

* To start the Agent Stack with Arize Phoenix use `--set phoenix.enabled=true`
* To start the Agent Stack with Docling use `--set docling.enabled=true`

```shell
agentstack platform start --set phoenix.enabled=true --set docling.enabled=true
```

### 3. Launch the UI

In your terminal, run:

```shell
agentstack ui
```

You should be prompted to select a model provider and model if you did not already set these.
For this lab, use Ollama and granite4:micro-h. for the language model.

You should see the UI launch in your browser.

!!! insight
If you navigate to the menu bar on the left hand side you will see a list of agents. These example agents come with Agent Stack. We'll add our custom agent in steps that follow.

### 4. Serve the agent

In your terminal, run the agent:

```shell
uv run src/agent.py --directory agentstack
```

!!! insight
If you take a look at the code pay special attention to the metadata in the `@server.agent` decorator. The metadata is used by the UI.

### 5. Run the agent

1. Navigate to the menu bar on the left hand side of the UI and select the Conference Prep Agent. You might need to refresh the page.

2. Notice that we build a form UI.

* `Task` is the main input to the agent.
* `Company name` is especially useful if your task doesn't mention the company name
* `Style` suggests the type of output you want. `detailed` is typically longer and may include source citations. `list` is a good option if you like bullet points.
* The `Event` name and `Event date` are used here primarily for UI demo purposes.

3. Experiment with the different form fields. Try using one of the following tasks:

* Brief me for a Shopify meeting at the conference. Give me an overview of the company, some recent news about them, and anything important I need to know from our internal notes.

* I'm planning on meeting the Moderna rep at the next conference. Remind me where we left off on previous discussions.

* Build a security talking sheet for Siemens Energy. How does their strategy compare to their competitors'?

4. Try different inputs.

5. Explore:

* the trajectory steps (look in "How did I get this answer?")
* the captured details in Arize Phoenix
* browse to `http://localhost:6006/`
* open project "default"
* Select "All" (not Root Spans)
* Most details show up after the run
* Look under "All" and not "Root"
* source citations (not always present)
45 changes: 45 additions & 0 deletions docs/opentech/agentstack/setup/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
title: Setup Instructions
description: Setup the repo and environment
logo: images/BeeAI-Logo-White.png
---

# Setup Instructions

## Get the Demo Code

**Option A: Clone with Git (Recommended):**

```bash
git clone https://github.com/IBM/beeai-workshop.git
```

**Option B: Download ZIP:**

If you're not comfortable with Git, [download the ZIP](https://github.com/IBM/beeai-workshop/archive/refs/heads/main.zip) file and extract it to your desired location.

---

## Navigate to the demo folder

Navigate to the specific demo folder:

```bash
cd beeai-workshop/opentech
```

**Important:**
Make sure to open the specific `opentech` folder, not the entire `beeai-workshop` directory.
This ensures proper project structure and dependencies are detected.

---

## Install Project Dependencies

1. **Install all required dependencies:**

```bash
uv --directory agentstack sync
```

This ensures you have the correct versions of all packages used in the lab, installed in the correct environment.
Loading
Loading