Skip to content

Commit

Permalink
more dotnet doc improvements (#5559)
Browse files Browse the repository at this point in the history
cleaning up the dotnet docs site, improving formatting, making the
landing page look more like the python
## Why are these changes needed?

---------

Co-authored-by: Jack Gerrits <[email protected]>
  • Loading branch information
rysweet and jackgerrits authored Feb 19, 2025
1 parent fa40568 commit 7e1f7a7
Show file tree
Hide file tree
Showing 4 changed files with 164 additions and 16 deletions.
15 changes: 9 additions & 6 deletions docs/dotnet/README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
## How to build and run the website
# How to build and run the website

### Prerequisites
- dotnet 7.0 or later
## Prerequisites

- dotnet 8.0 or later

## Build

### Build
Firstly, go to autogen/dotnet folder and run the following command to build the website:

```bash
dotnet tool restore
dotnet tool run docfx website/docfx.json --serve
dotnet tool run docfx ../docs/dotnet/docfx.json --serve
```

After the command is executed, you can open your browser and navigate to `http://localhost:8080` to view the website.
After the command is executed, you can open your browser and navigate to `http://localhost:8080` to view the website.
6 changes: 5 additions & 1 deletion docs/dotnet/docfx.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@
{
"files": [
"src/Microsoft.AutoGen/Core/**/*.csproj",
"src/Microsoft.AutoGen/Contracts/**/*.csproj"
"src/Microsoft.AutoGen/Contracts/**/*.csproj",
"src/Microsoft.AutoGen/Core.Grpc/**/*.csproj",
"src/Microsoft.AutoGen/AgentHost/**/*.csproj",
"src/Microsoft.AutoGen/RuntimeGateway.Grpc/**/*.csproj",
"src/Microsoft.AutoGen/Extensions/**/*.csproj"
],
"src": "../../dotnet/"
}
Expand Down
48 changes: 39 additions & 9 deletions docs/dotnet/index.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,6 @@
---
_disableAffix: true
---
<style>
.center {
text-align: center;
}

.subheader {
font-size: 1.5em;
}
</style>

<div class="center">
<h1>AutoGen .NET</h1>
Expand All @@ -23,7 +14,46 @@ _disableAffix: true
<div class="card">
<div class="card-body">
<h5 class="card-title">Core</h5>
<p>

[![dotnet-ci](https://github.com/microsoft/autogen/actions/workflows/dotnet-build.yml/badge.svg)](https://github.com/microsoft/autogen/actions/workflows/dotnet-build.yml)
[![NuGet version](https://badge.fury.io/nu/Microsoft.AutoGen.Contracts.svg)](https://badge.fury.io/nu/Microsoft.AutoGen.Contracts)
[![NuGet version](https://badge.fury.io/nu/Microsoft.AutoGen.Core.svg)](https://badge.fury.io/nu/Microsoft.AutoGen.Core)
[![NuGet version](https://badge.fury.io/nu/Microsoft.AutoGen.Core.Grpc.svg)](https://badge.fury.io/nu/Microsoft.AutoGen.Core.Grpc)
[![NuGet version](https://badge.fury.io/nu/Microsoft.AutoGen.RuntimeGateway.Grpc.svg)](https://badge.fury.io/nu/Microsoft.AutoGen.RuntimeGateway.Grpc)
[![NuGet version](https://badge.fury.io/nu/Microsoft.AutoGen.AgentHost.svg)](https://badge.fury.io/nu/Microsoft.AutoGen.AgentHost)

</p>
<p class="card-text">An event-driven programming framework for building scalable multi-agent AI systems.</p>

- Deterministic and dynamic agentic workflows for business processes
- Research on multi-agent collaboration
- Distributed agents for multi-language applications
- integration with event-driven, cloud native applications

*Start here if you are building workflows or distributed agent systems*

<p>
<div class="highlight">
<pre id="codecell0" tabindex="0">

```bash
dotnet add package Microsoft.AutoGen.Contracts
dotnet add package Microsoft.AutoGen.Core

# optionally - for distributed agent systems:
dotnet add package Microsoft.AutoGen.RuntimeGateway.Grpc
dotnet add package Microsoft.AutoGen.AgentHost

# other optional packages
dotnet add package Microsoft.AutoGen.Agents
dotnet add package Microsoft.AutoGen.Extensions.Aspire
dotnet add package Microsoft.AutoGen.Extensions.MEAI
dotnet add package Microsoft.AutoGen.Extensions.SemanticKernel
```

</pre></div></p>
<p>
<a href="core/index.md" class="btn btn-primary">Get started</a>
</div>
</div>
Expand Down
111 changes: 111 additions & 0 deletions docs/dotnet/template/public/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,114 @@
height: 50px;
margin-right: 0.5rem;
}
.bd-footer {
font-size: 0.8rem;
}

html[data-theme="light"] {
--pst-color-primary: hsl(222.2 47.4% 11.2%);
--pst-color-secondary: #007bff;
--pst-color-secondary-bg: #007bff;
--pst-color-accent: #007bff;
--sd-color-secondary-highlight: #0062cc;
--pst-color-shadow: rgba(0, 0, 0, 0.0);
}

html[data-theme="dark"] {
--pst-color-primary: hsl(213 31% 91%);
--pst-color-secondary: #007bff;
--pst-color-secondary-bg: #007bff;
--pst-color-accent: #007bff;
--sd-color-secondary-highlight: #0062cc;
--pst-color-shadow: rgba(0, 0, 0, 0.0);
}

.bd-header-announcement {
color: white;
}

.bd-header-announcement a {
color: white;
}

.bd-header-announcement a:hover {
color: white;
text-shadow: 0.5px 0 0 currentColor;
}

nav.bd-links .current>a {
box-shadow: inset 1px 0 0 var(--pst-color-primary);
}

html[data-theme="light"] .bd-header {
border-bottom: 1px solid var(--pst-color-border);
}

.admonition, div.admonition {
border: 1px solid var(--pst-color-border);
}

.api-card {
text-align: center;
font-size: 1.2rem;
}

.api-card svg {
font-size: 2rem;
}

.search-button-field {
border-radius: var(--bs-btn-border-radius);
}

.bd-content .sd-tab-set .sd-tab-content {
border: none;
border-top: 3px solid var(--pst-color-border);

}
.bd-content .sd-tab-set>input:checked+label {
border: none;
transform: translateY(0);
font-weight: 600;
border-bottom: 2px solid var(--pst-color-secondary);

}
.bd-content .sd-tab-set>label {
background-color: transparent;
border: none;
}

.center {
text-align: center;
}

.subheader {
font-size: 1.5em;
}
.hero-title {
font-size: 60px;
font-weight: bold;
margin: 2rem auto 0;
}

.wip-card {
border: 1px solid var(--pst-color-success);
background-color: var(--pst-color-success-bg);
border-radius: .25rem;
padding: 0.3rem;
display: flex;
justify-content: center;
align-items: center;
margin-bottom: 1rem;
}
.card-title {
font-size: 1.2rem;
font-weight: bold;
}

.card-title svg {
font-size: 2rem;
vertical-align: bottom;
margin-right: 5px;
}

0 comments on commit 7e1f7a7

Please sign in to comment.