Docs: Update architecture diagram with Google colors (for future aricles) (#718)

This commit is contained in:
Riccardo Carlesso 2025-06-04 21:33:07 +02:00 committed by GitHub
parent 4192cfb092
commit 13b55c6e68
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 20 additions and 8 deletions

View File

@ -57,14 +57,26 @@ A typical interaction with the Gemini CLI follows this general flow:
graph TD
User[User via Terminal] -- Input --> CLI[packages/cli]
CLI -- Request --> Core[packages/core]
Core -- Prompt/Tool Info --> GeminiAPI[Gemini API]
GeminiAPI -- Response/Tool Call --> Core
Core -- Tool Details --> CLI
CLI -- User Confirms --> Core
Core -- Execute Tool --> Tools[Tools e.g., read_file, shell]
Tools -- Tool Result --> Core
Core -- Final Response --> CLI
Core -- Prompt/ToolInfo --> GeminiAPI[Gemini API]
GeminiAPI -- Response/ToolCall --> Core
Core -- ToolDetails --> CLI
CLI -- UserConfirms --> Core
Core -- ExecuteTool --> Tools[Tools e.g., read_file, shell]
Tools -- ToolResult --> Core
Core -- FinalResponse --> CLI
CLI -- Output --> User
classDef userStyle fill:#FFFFFF,stroke:#333333,stroke-width:2px
classDef cliStyle fill:#FBBC05,stroke:#000000,stroke-width:2px
classDef coreStyle fill:#34A853,stroke:#000000,stroke-width:2px
classDef apiStyle fill:#4285F4,stroke:#3F51B5,stroke-width:2px
classDef toolsStyle fill:#EA4335,stroke:#000000,stroke-width:2px
class User userStyle
class CLI cliStyle
class Core coreStyle
class GeminiAPI apiStyle
class Tools toolsStyle
```
## Key Design Principles

View File

@ -69,4 +69,4 @@ While direct programmatic registration of new tools by users isn't explicitly de
- **Command-based Discovery:** Advanced users or project administrators can define a `toolDiscoveryCommand` in `settings.json`. This command, when run by the Gemini CLI core, should output a JSON array of `FunctionDeclaration` objects. The core will then make these available as `DiscoveredTool` instances. The corresponding `toolCallCommand` would then be responsible for actually executing these custom tools.
- **MCP Server(s):** For more complex scenarios, one or more MCP servers can be set up and configured via the `mcpServers` setting in `settings.json`. The Gemini CLI core can then discover and use tools exposed by these servers. As mentioned, if you have multiple MCP servers, the tool names will be prefixed with the server name from your configuration (e.g., `serverAlias__actualToolName`).
This tool system provides a flexible and powerful way to augment the Gemini model\'s capabilities, making the Gemini CLI a versatile assistant for a wide range of tasks.
This tool system provides a flexible and powerful way to augment the Gemini model's capabilities, making the Gemini CLI a versatile assistant for a wide range of tasks.