Skip to content

[docs] Visualization of the open-interpreter codebase #1632

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
93 changes: 93 additions & 0 deletions .codeboarding/Application_Management.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
```mermaid

graph LR

User_Profile_Manager["User Profile Manager"]

Conversation_Contribution_Manager["Conversation Contribution Manager"]

Application_Lifecycle_Manager["Application Lifecycle Manager"]

Application_Lifecycle_Manager -- "uses" --> User_Profile_Manager

Application_Lifecycle_Manager -- "uses" --> Conversation_Contribution_Manager

User_Profile_Manager -- "interacts with" --> File_System

Conversation_Contribution_Manager -- "interacts with" --> Telemetry_System

Conversation_Contribution_Manager -- "interacts with" --> File_System

```

[![CodeBoarding](https://img.shields.io/badge/Generated%20by-CodeBoarding-9cf?style=flat-square)](https://github.com/CodeBoarding/GeneratedOnBoardings)[![Demo](https://img.shields.io/badge/Try%20our-Demo-blue?style=flat-square)](https://www.codeboarding.org/demo)[![Contact](https://img.shields.io/badge/Contact%20us%20-%20contact@codeboarding.org-lightgrey?style=flat-square)](mailto:contact@codeboarding.org)



## Component Details



Application Management subsystem



### User Profile Manager

This component is dedicated to managing user profiles, which store configuration settings, preferences, and other user-specific data. It provides functionalities to retrieve, apply, reset, and migrate user profiles, ensuring that the interpreter operates according to the user's personalized settings and maintains state across sessions.





**Related Classes/Methods**:



- <a href="https://github.com/OpenInterpreter/open-interpreter/blob/master/interpreter/terminal_interface/profiles/profiles.py#L1-L1" target="_blank" rel="noopener noreferrer">`interpreter.terminal_interface.profiles.profiles` (1:1)</a>





### Conversation Contribution Manager

This component is responsible for managing the collection, storage, and submission of user conversation data. It handles the logic for retrieving past conversations, prompting the user for contribution consent, and writing conversation data to a cache. Its primary purpose is to facilitate the improvement of the interpreter by allowing users to share their interaction data for telemetry and model enhancement.





**Related Classes/Methods**:



- <a href="https://github.com/OpenInterpreter/open-interpreter/blob/master/interpreter/terminal_interface/contributing_conversations.py#L1-L1" target="_blank" rel="noopener noreferrer">`interpreter.terminal_interface.contributing_conversations` (1:1)</a>





### Application Lifecycle Manager

This component orchestrates the overall startup and shutdown of the application's terminal interface. It handles initial setup tasks such as parsing command-line arguments, validating LLM settings, and coordinating with other core components like the User Profile Manager and Conversation Contribution Manager to initialize the application environment.





**Related Classes/Methods**:



- <a href="https://github.com/OpenInterpreter/open-interpreter/blob/master/interpreter/terminal_interface/start_terminal_interface.py#L18-L577" target="_blank" rel="noopener noreferrer">`interpreter.terminal_interface.start_terminal_interface` (18:577)</a>









### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq)
277 changes: 277 additions & 0 deletions .codeboarding/Computer_Interaction_Layer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,277 @@
```mermaid

graph LR

Computer_Interaction_Layer["Computer Interaction Layer"]

AI_Tool["AI Tool"]

Browser_Tool["Browser Tool"]

Terminal_Tool["Terminal Tool"]

Files_Tool["Files Tool"]

Display_Tool["Display Tool"]

Keyboard_Tool["Keyboard Tool"]

Mouse_Tool["Mouse Tool"]

OS_Tool["OS Tool"]

Base_Language["Base Language"]

Interpreter_Core["Interpreter Core"]

Specific_Language_Implementations["Specific Language Implementations"]

Interpreter_Core -- "uses" --> Computer_Interaction_Layer

Computer_Interaction_Layer -- "is composed of" --> AI_Tool

Computer_Interaction_Layer -- "is composed of" --> Browser_Tool

Computer_Interaction_Layer -- "is composed of" --> Terminal_Tool

Computer_Interaction_Layer -- "is composed of" --> Files_Tool

Computer_Interaction_Layer -- "is composed of" --> Display_Tool

Computer_Interaction_Layer -- "is composed of" --> Keyboard_Tool

Computer_Interaction_Layer -- "is composed of" --> Mouse_Tool

Computer_Interaction_Layer -- "is composed of" --> OS_Tool

Terminal_Tool -- "uses" --> Base_Language

Base_Language -- "is extended by" --> Specific_Language_Implementations

click Computer_Interaction_Layer href "https://github.com/OpenInterpreter/open-interpreter/blob/main/.codeboarding//Computer_Interaction_Layer.md" "Details"

click Interpreter_Core href "https://github.com/OpenInterpreter/open-interpreter/blob/main/.codeboarding//Interpreter_Core.md" "Details"

```

[![CodeBoarding](https://img.shields.io/badge/Generated%20by-CodeBoarding-9cf?style=flat-square)](https://github.com/CodeBoarding/GeneratedOnBoardings)[![Demo](https://img.shields.io/badge/Try%20our-Demo-blue?style=flat-square)](https://www.codeboarding.org/demo)[![Contact](https://img.shields.io/badge/Contact%20us%20-%20contact@codeboarding.org-lightgrey?style=flat-square)](mailto:contact@codeboarding.org)



## Component Details



The Computer Interaction Layer is a critical subsystem within the project, designed to provide the Interpreter Core with a unified and high-level programmatic interface for interacting with the underlying computer system. It achieves this by aggregating and managing various specialized computer tools, thereby abstracting the complexities of direct system interaction. This design is fundamental as it isolates the core logic of the interpreter from the specifics of operating system interactions, enhancing portability, maintainability, and extensibility.



### Computer Interaction Layer

The primary component that acts as a central hub, providing a unified, high-level programmatic interface for the Interpreter Core to interact with the underlying computer system. It aggregates and manages various specialized computer tools, abstracting the complexities of direct system interaction (e.g., file system, browser, display, AI capabilities).





**Related Classes/Methods**:



- `Computer Interaction Layer` (1:1)





### AI Tool

Provides an interface for the interpreter to interact with AI capabilities, such as image recognition or natural language processing.





**Related Classes/Methods**:



- `AI Tool` (1:1)





### Browser Tool

Enables the interpreter to programmatically control and interact with a web browser for tasks like navigation, data extraction, or web application automation.





**Related Classes/Methods**:



- `Browser Tool` (1:1)





### Terminal Tool

Provides an interface for executing commands in the system terminal and capturing their output, supporting various programming languages.





**Related Classes/Methods**:



- `Terminal Tool` (1:1)





### Files Tool

Manages file system operations, including reading, writing, creating, and deleting files and directories.





**Related Classes/Methods**:



- `Files Tool` (1:1)





### Display Tool

Manages interactions with the computer's display, potentially for screen capture, display settings, or rendering information.





**Related Classes/Methods**:



- `Display Tool` (1:1)





### Keyboard Tool

Enables programmatic control of the keyboard for simulating key presses and input.





**Related Classes/Methods**:



- `Keyboard Tool` (1:1)





### Mouse Tool

Enables programmatic control of the mouse for simulating movements and clicks.





**Related Classes/Methods**:



- `Mouse Tool` (1:1)





### OS Tool

Provides an interface for interacting with the operating system, offering functionalities like system information retrieval, process management, and environment variable access.





**Related Classes/Methods**:



- `OS Tool` (1:1)





### Base Language

An abstract base class that defines the common interface and functionalities for all specific language implementations used by the Terminal Tool. This includes methods for executing code and handling output.





**Related Classes/Methods**:



- `Base Language` (1:1)





### Interpreter Core

The core logic of the interpreter that uses the Computer Interaction Layer.





**Related Classes/Methods**: _None_



### Specific Language Implementations

Various specific language implementations (e.g., Python, JavaScript, Shell) that extend the Base Language.





**Related Classes/Methods**: _None_







### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq)
Loading