Skip to content

Commit

Permalink
Upgrade Quarto and use notebook metadata for frontmatter (microsoft#1836
Browse files Browse the repository at this point in the history
)

* Update process_notebook to use metadata instead of a yaml comment

* upgrade quarto and version check in tool

* formatting

* address comments
  • Loading branch information
jackgerrits authored Mar 2, 2024
1 parent 97923ee commit d604643
Show file tree
Hide file tree
Showing 18 changed files with 208 additions and 244 deletions.
8 changes: 4 additions & 4 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ RUN apt-get update \
&& apt-get -y install --no-install-recommends build-essential npm \
&& apt-get autoremove -y \
&& apt-get clean -y \
&& wget https://github.com/quarto-dev/quarto-cli/releases/download/v1.4.549/quarto-1.4.549-linux-amd64.deb \
&& dpkg -i quarto-1.4.549-linux-amd64.deb \
&& rm -rf /var/lib/apt/lists/* quarto-1.4.549-linux-amd64.deb
&& wget https://github.com/quarto-dev/quarto-cli/releases/download/v1.5.23/quarto-1.5.23-linux-amd64.deb \
&& dpkg -i quarto-1.5.23-linux-amd64.deb \
&& rm -rf /var/lib/apt/lists/* quarto-1.5.23-linux-amd64.deb
ENV DEBIAN_FRONTEND=dialog

# For docs
RUN npm install --global yarn
RUN pip install pydoc-markdown
RUN pip install pyyaml
RUN pip install colored
RUN pip install colored
8 changes: 4 additions & 4 deletions .devcontainer/dev/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,12 @@ RUN cd website
RUN yarn install --frozen-lockfile --ignore-engines

RUN arch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/amd64/) && \
wget -q https://github.com/quarto-dev/quarto-cli/releases/download/v1.4.549/quarto-1.4.549-linux-${arch}.tar.gz && \
wget -q https://github.com/quarto-dev/quarto-cli/releases/download/v1.5.23/quarto-1.5.23-linux-${arch}.tar.gz && \
mkdir -p /home/autogen/quarto/ && \
tar -xzf quarto-1.4.549-linux-${arch}.tar.gz --directory /home/autogen/quarto/ && \
rm quarto-1.4.549-linux-${arch}.tar.gz
tar -xzf quarto-1.5.23-linux-${arch}.tar.gz --directory /home/autogen/quarto/ && \
rm quarto-1.5.23-linux-${arch}.tar.gz

ENV PATH="${PATH}:/home/autogen/quarto/quarto-1.4.549/bin/"
ENV PATH="${PATH}:/home/autogen/quarto/quarto-1.5.23/bin/"

# Exposes the Yarn port for Docusaurus
EXPOSE 3000
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/deploy-website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ jobs:
- name: quarto install
working-directory: ${{ runner.temp }}
run: |
wget -q https://github.com/quarto-dev/quarto-cli/releases/download/v1.4.549/quarto-1.4.549-linux-amd64.tar.gz
tar -xzf quarto-1.4.549-linux-amd64.tar.gz
echo "$(pwd)/quarto-1.4.549/bin/" >> $GITHUB_PATH
wget -q https://github.com/quarto-dev/quarto-cli/releases/download/v1.5.23/quarto-1.5.23-linux-amd64.tar.gz
tar -xzf quarto-1.5.23-linux-amd64.tar.gz
echo "$(pwd)/quarto-1.5.23/bin/" >> $GITHUB_PATH
- name: quarto run
run: |
quarto render .
Expand Down Expand Up @@ -90,9 +90,9 @@ jobs:
- name: quarto install
working-directory: ${{ runner.temp }}
run: |
wget -q https://github.com/quarto-dev/quarto-cli/releases/download/v1.4.549/quarto-1.4.549-linux-amd64.tar.gz
tar -xzf quarto-1.4.549-linux-amd64.tar.gz
echo "$(pwd)/quarto-1.4.549/bin/" >> $GITHUB_PATH
wget -q https://github.com/quarto-dev/quarto-cli/releases/download/v1.5.23/quarto-1.5.23-linux-amd64.tar.gz
tar -xzf quarto-1.5.23-linux-amd64.tar.gz
echo "$(pwd)/quarto-1.5.23/bin/" >> $GITHUB_PATH
- name: quarto run
run: |
quarto render .
Expand Down
14 changes: 6 additions & 8 deletions notebook/agentchat_RetrieveChat.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"RAG\"]\n",
"description: |\n",
" Explore the use of AutoGen's RetrieveChat for tasks like code generation from docstrings, answering complex questions with human feedback, and exploiting features like Update Context, custom prompts, and few-shot learning.\n",
"-->\n",
"\n",
"# Using RetrieveChat for Retrieve Augmented Code Generation and Question Answering\n",
"\n",
"AutoGen offers conversable agents powered by LLM, tool or human, which can be used to perform tasks collectively via automated chat. This framework allows tool use and human participation through multi-agent conversation.\n",
Expand Down Expand Up @@ -3020,6 +3014,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["RAG"],
"description": "Explore the use of AutoGen's RetrieveChat for tasks like code generation from docstrings, answering complex questions with human feedback, and exploiting features like Update Context, custom prompts, and few-shot learning."
},
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
Expand All @@ -3036,8 +3034,8 @@
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.12"
},
"test_skip": "Requires interactive usage"
},
"skip_test": "Requires interactive usage"
},
"nbformat": 4,
"nbformat_minor": 4
Expand Down
13 changes: 7 additions & 6 deletions notebook/agentchat_auto_feedback_from_code_execution.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,6 @@
}
},
"source": [
"<!--\n",
"tags: [\"code generation\", \"debugging\"]\n",
"description: |\n",
" Use conversable language learning model agents to solve tasks and provide automatic feedback through a comprehensive example of writing, executing, and debugging Python code to compare stock price changes.\n",
"-->\n",
"\n",
"# Task Solving with Code Generation, Execution and Debugging\n",
"\n",
"AutoGen offers conversable LLM agents, which can be used to solve various tasks with human or automatic feedback, including tasks that require using tools via code.\n",
Expand Down Expand Up @@ -1098,6 +1092,13 @@
}
],
"metadata": {
"front_matter": {
"tags": [
"code generation",
"debugging"
],
"description": "Use conversable language learning model agents to solve tasks and provide automatic feedback through a comprehensive example of writing, executing, and debugging Python code to compare stock price changes."
},
"kernelspec": {
"display_name": "Python 3",
"language": "python",
Expand Down
10 changes: 4 additions & 6 deletions notebook/agentchat_function_call_async.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@
"id": "ae1f50ec",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"code generation\", \"function call\", \"async\"]\n",
"description: |\n",
" Learn how to implement both synchronous and asynchronous function calls using AssistantAgent and UserProxyAgent in AutoGen, with examples of their application in individual and group chat settings for task execution with language models.\n",
"-->\n",
"\n",
"# Task Solving with Provided Tools as Functions (Asynchronous Function Calls)\n"
]
},
Expand Down Expand Up @@ -366,6 +360,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["code generation", "function call", "async"],
"description": "Learn how to implement both synchronous and asynchronous function calls using AssistantAgent and UserProxyAgent in AutoGen, with examples of their application in individual and group chat settings for task execution with language models."
},
"kernelspec": {
"display_name": "flaml_dev",
"language": "python",
Expand Down
10 changes: 4 additions & 6 deletions notebook/agentchat_groupchat.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"orchestration\", \"group chat\"]\n",
"description: |\n",
" Explore the utilization of large language models in automated group chat scenarios, where agents perform tasks collectively, demonstrating how they can be configured, interact with each other, and retrieve specific information from external resources.\n",
"-->\n",
"\n",
"# Group Chat\n",
"\n",
"AutoGen offers conversable agents powered by LLM, tool or human, which can be used to perform tasks collectively via automated chat. This framework allows tool use and human participation through multi-agent conversation.\n",
Expand Down Expand Up @@ -223,6 +217,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["orchestration", "group chat"],
"description": "Explore the utilization of large language models in automated group chat scenarios, where agents perform tasks collectively, demonstrating how they can be configured, interact with each other, and retrieve specific information from external resources."
},
"kernelspec": {
"display_name": "flaml",
"language": "python",
Expand Down
18 changes: 5 additions & 13 deletions notebook/agentchat_groupchat_RAG.ipynb
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
{
"cells": [
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"group chat\", \"orchestration\", \"RAG\"]\n",
"description: |\n",
" Implement and manage a multi-agent chat system using AutoGen, where AI assistants retrieve information, generate code, and interact collaboratively to solve complex tasks, especially in areas not covered by their training data.\n",
"-->"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down Expand Up @@ -1120,6 +1108,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["group chat", "orchestration", "RAG"],
"description": "Implement and manage a multi-agent chat system using AutoGen, where AI assistants retrieve information, generate code, and interact collaboratively to solve complex tasks, especially in areas not covered by their training data."
},
"kernelspec": {
"display_name": "flaml",
"language": "python",
Expand All @@ -1135,7 +1127,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.13"
"version": "3.11.7"
}
},
"nbformat": 4,
Expand Down
14 changes: 7 additions & 7 deletions notebook/agentchat_groupchat_finite_state_machine.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"orchestration\"]\n",
"description: |\n",
" Explore the demonstration of the Finite State Machine implementation, which allows the user to input speaker transition contraints.\n",
"-->\n",
"\n",
"# FSM - User can input speaker transition contraints.\n",
"# FSM - User can input speaker transition constraints\n",
"\n",
"AutoGen offers conversable agents powered by LLM, tool, or human, which can be used to perform tasks collectively via automated chat. This framework allows tool use and human participation through multi-agent conversation.\n",
"Please find documentation about this feature [here](https://microsoft.github.io/autogen/docs/Use-Cases/agent_chat).\n",
Expand Down Expand Up @@ -597,6 +591,12 @@
}
],
"metadata": {
"front_matter": {
"description": "Explore the demonstration of the Finite State Machine implementation, which allows the user to input speaker transition constraints.",
"tags": [
"orchestration"
]
},
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
Expand Down
15 changes: 8 additions & 7 deletions notebook/agentchat_logging.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"logging\", \"debugging\"]\n",
"description: |\n",
" Provide capabilities of runtime logging for debugging and performance analysis.\n",
"-->\n",
"\n",
"# Runtime Logging with AutoGen \n",
"\n",
"AutoGen offers utilities to log data for debugging and performance analysis. This notebook demonstrates how to use them. \n",
Expand Down Expand Up @@ -294,6 +288,13 @@
}
],
"metadata": {
"front_matter": {
"description": "Provide capabilities of runtime logging for debugging and performance analysis.",
"tags": [
"logging",
"debugging"
]
},
"kernelspec": {
"display_name": "autog",
"language": "python",
Expand All @@ -309,7 +310,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.13"
"version": "3.11.7"
}
},
"nbformat": 4,
Expand Down
12 changes: 5 additions & 7 deletions notebook/agentchat_multi_task_async_chats.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,6 @@
}
},
"source": [
"<!--\n",
"tags: [\"sequential chat\"]\n",
"description: |\n",
" Use conversational agents to solve a set of tasks with a sequence of async chats.\n",
"-->\n",
"\n",
"# Solving Multiple Tasks in a Sequence of Async Chats\n",
"\n",
"This notebook showcases how to use the new chat interface of conversational agents in AutoGen: a_initiate_chats, to conduct a series of tasks. Similar to \"notebook/agentchat_microsoft_fabric.ipynb\", this new interface allows one to pass multiple tasks and their corresponding dedicated agents and execute concurrently. Depending on the prerequisite task(s), the tasks will be solved concurrently, with the summaries from prerequisite task(s) provided to subsequent tasks as context, if the `summary_method` argument is specified.\n",
Expand Down Expand Up @@ -1484,6 +1478,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["sequential chat"],
"description": "Use conversational agents to solve a set of tasks with a sequence of async chats."
},
"kernelspec": {
"display_name": "Python 3",
"language": "python",
Expand All @@ -1499,7 +1497,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.8"
"version": "3.11.7"
},
"vscode": {
"interpreter": {
Expand Down
12 changes: 6 additions & 6 deletions notebook/agentchat_multi_task_chats.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,6 @@
}
},
"source": [
"<!--\n",
"tags: [\"sequential chat\"]\n",
"description: |\n",
" Use conversational agents to solve a set of tasks with a sequence of chats.\n",
"-->\n",
"\n",
"# Solving Multiple Tasks in a Sequence of Chats\n",
"\n",
"This notebook showcases how to use the new chat interface of conversational agents in AutoGen: initiate_chats, to conduct a series of tasks. This new interface allows one to pass multiple tasks and their corresponding dedicated agents. Once initiate_chats is invoked, the tasks will be solved sequentially, with the summaries from previous tasks provided to subsequent tasks as context, if the `summary_method` argument is specified.\n",
Expand Down Expand Up @@ -1536,6 +1530,12 @@
}
],
"metadata": {
"front_matter": {
"description": "Use conversational agents to solve a set of tasks with a sequence of chats.",
"tags": [
"sequential chat"
]
},
"kernelspec": {
"display_name": "Python 3",
"language": "python",
Expand Down
10 changes: 4 additions & 6 deletions notebook/agentchat_nestedchat.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,6 @@
}
},
"source": [
"<!--\n",
"tags: [\"nested chat\"]\n",
"description: |\n",
" Solve complex tasks with one or more sequence chats nested as inner monologue.\n",
"-->\n",
"\n",
"# Solving Complex Tasks with Nested Chats\n",
"\n",
"This notebook shows how you can leverage \"nested chats\" to solve complex task with AutoGen. Nested chats allow AutoGen agents to use other agents as their inner monologue to accomplish tasks. This abstraction is powerful as it allows you to compose agents in rich ways. This notebook shows how you can nest a pretty complex sequence of chats among _inner_ agents inside an _outer_ agent.\n",
Expand Down Expand Up @@ -814,6 +808,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["nested chat"],
"description": "Solve complex tasks with one or more sequence chats nested as inner monologue."
},
"kernelspec": {
"display_name": "Python 3",
"language": "python",
Expand Down
10 changes: 4 additions & 6 deletions notebook/agentchat_society_of_mind.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<!--\n",
"tags: [\"orchestration\"]\n",
"description: |\n",
" Explore the demonstration of the SocietyOfMindAgent in the AutoGen library, which runs a group chat as an internal monologue, but appears to the external world as a single agent, offering a structured way to manage complex interactions among multiple agents and handle issues such as extracting responses from complex dialogues and dealing with context window constraints.\n",
"-->\n",
"\n",
"# SocietyOfMindAgent\n",
"\n",
"This notebook demonstrates the SocietyOfMindAgent, which runs a group chat as an internal monologue, but appears to the external world as a single agent. This confers three distinct advantages:\n",
Expand Down Expand Up @@ -362,6 +356,10 @@
}
],
"metadata": {
"front_matter": {
"tags": ["orchestration"],
"description": "Explore the demonstration of the SocietyOfMindAgent in the AutoGen library, which runs a group chat as an internal monologue, but appears to the external world as a single agent, offering a structured way to manage complex interactions among multiple agents and handle issues such as extracting responses from complex dialogues and dealing with context window constraints."
},
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
Expand Down
Loading

0 comments on commit d604643

Please sign in to comment.