Skip to content

Commit 4325d79

Browse files
committed
docs: update codeboarding documentation in advanced-customization
## 📚 Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the advanced-customization section. ### 📊 Summary - Documentation files created/updated: 8 - JSON files created/updated: 9 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/Pipelex/pipelex - Destination: docs/pages/advanced-customization/ The generated .md files have been automatically copied to the advanced-customization documentation section. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow.
1 parent fa46da2 commit 4325d79

35 files changed

+2676
-1399
lines changed
Lines changed: 194 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,194 @@
1+
{
2+
"description": "The `pipelex` system leverages a flexible architecture for integrating various AI model backends. The `ModelBackendManager` serves as the central hub, abstracting the complexities of different AI providers. It interacts with standardized interfaces like `LLMInterface` for Large Language Models and `ImageGenerationInterface` for image generation, ensuring a consistent API for the rest of the system. Concrete implementations, such as `OpenAIIntegration`, provide the actual communication with external AI services, translating generic requests into provider-specific API calls and handling responses. This design allows for easy extension and interchangeability of AI backends, promoting modularity and adaptability within the `pipelex` ecosystem.",
3+
"components": [
4+
{
5+
"name": "ModelBackendManager",
6+
"description": "This component is responsible for registering, configuring, and dynamically routing requests to various AI model backends. It acts as the central dispatcher, abstracting provider-specific details and presenting a unified interface to the rest of the `pipelex` system. It ensures that workflows can seamlessly switch between or utilize different AI providers without direct knowledge of their underlying APIs.",
7+
"referenced_source_code": [
8+
{
9+
"qualified_name": "pipelex.cogt.model_backends.backend.InferenceBackend",
10+
"reference_file": "pipelex/cogt/model_backends/backend.py",
11+
"reference_start_line": 9,
12+
"reference_end_line": 28
13+
}
14+
],
15+
"assigned_files": [
16+
"pipelex/cogt/model_backends",
17+
"pipelex/cogt/model_backends/backend.py",
18+
"pipelex/cogt/model_backends/backend_factory.py",
19+
"pipelex/cogt/model_backends/__init__.py",
20+
"pipelex/cogt/model_backends/model_constraints.py",
21+
"pipelex/cogt/model_backends/model_spec_factory.py",
22+
"pipelex/cogt/model_backends/prompting_target.py",
23+
"pipelex/cogt/model_backends/model_lists.py",
24+
"pipelex/cogt/model_backends/backend_library.py",
25+
"pipelex/cogt/model_backends/model_spec.py",
26+
"pipelex/cogt/model_backends/model_type.py",
27+
"pipelex/cogt/model_routing/routing_profile_loader.py",
28+
"pipelex/cogt/model_routing/routing_models.py",
29+
"pipelex/cogt/model_routing/__init__.py",
30+
"pipelex/cogt/model_routing/routing_profile_factory.py",
31+
"pipelex/cogt/model_routing/routing_profile.py",
32+
"pipelex/cogt/model_backends"
33+
],
34+
"can_expand": true
35+
},
36+
{
37+
"name": "LLMInterface",
38+
"description": "Defines a standardized API for interacting with Large Language Models. This interface specifies methods for common NLP tasks such as text generation, summarization, and embeddings, ensuring consistency across different LLM implementations.",
39+
"referenced_source_code": [
40+
{
41+
"qualified_name": "pipelex.cogt.llm.llm_worker_abstract.LLMWorkerAbstract",
42+
"reference_file": "pipelex/cogt/llm/llm_worker_abstract.py",
43+
"reference_start_line": 18,
44+
"reference_end_line": 129
45+
}
46+
],
47+
"assigned_files": [
48+
"pipelex/cogt/llm",
49+
"pipelex/cogt/llm/llm_job.py",
50+
"pipelex/cogt/llm/llm_job_components.py",
51+
"pipelex/cogt/llm/llm_prompt_template.py",
52+
"pipelex/cogt/llm/__init__.py",
53+
"pipelex/cogt/llm/llm_utils.py",
54+
"pipelex/cogt/llm/llm_worker_abstract.py",
55+
"pipelex/cogt/llm/llm_setting.py",
56+
"pipelex/cogt/llm/llm_worker_factory.py",
57+
"pipelex/cogt/llm/llm_worker_internal_abstract.py",
58+
"pipelex/cogt/llm/llm_job_factory.py",
59+
"pipelex/cogt/llm/llm_prompt_factory_abstract.py",
60+
"pipelex/cogt/llm/llm_report.py",
61+
"pipelex/cogt/llm/llm_prompt.py",
62+
"pipelex/cogt/llm/structured_output.py",
63+
"pipelex/cogt/llm/llm_prompt_template_inputs.py",
64+
"pipelex/cogt/llm"
65+
],
66+
"can_expand": true
67+
},
68+
{
69+
"name": "ImageGenerationInterface",
70+
"description": "Provides a standardized API for generating images based on textual prompts or other inputs. Similar to the `LLMInterface`, it ensures a consistent way for the `pipelex` system to request image generation from various providers.",
71+
"referenced_source_code": [
72+
{
73+
"qualified_name": "pipelex.cogt.img_gen.img_gen_worker_abstract.ImgGenWorkerAbstract",
74+
"reference_file": "pipelex/cogt/img_gen/img_gen_worker_abstract.py",
75+
"reference_start_line": 14,
76+
"reference_end_line": 106
77+
}
78+
],
79+
"assigned_files": [
80+
"pipelex/cogt/img_gen",
81+
"pipelex/cogt/image/prompt_image.py",
82+
"pipelex/cogt/image/__init__.py",
83+
"pipelex/cogt/image/prompt_image_factory.py",
84+
"pipelex/cogt/image/generated_image.py",
85+
"pipelex/cogt/img_gen/img_gen_job_components.py",
86+
"pipelex/cogt/img_gen/__init__.py",
87+
"pipelex/cogt/img_gen/img_gen_worker_abstract.py",
88+
"pipelex/cogt/img_gen/img_gen_job.py",
89+
"pipelex/cogt/img_gen/img_gen_worker_factory.py",
90+
"pipelex/cogt/img_gen/img_gen_setting.py",
91+
"pipelex/cogt/img_gen/img_gen_job_factory.py",
92+
"pipelex/cogt/img_gen/img_gen_prompt.py",
93+
"pipelex/cogt/img_gen"
94+
],
95+
"can_expand": true
96+
},
97+
{
98+
"name": "OpenAIIntegration",
99+
"description": "This component handles the direct communication and API calls to the OpenAI platform. It translates generic requests from the `LLMInterface` and `ImageGenerationInterface` into OpenAI-specific API calls and processes the responses, acting as a concrete implementation for OpenAI services.",
100+
"referenced_source_code": [
101+
{
102+
"qualified_name": "pipelex.plugins.openai.openai_llm_worker.OpenAILLMWorker",
103+
"reference_file": "pipelex/plugins/openai/openai_llm_worker.py",
104+
"reference_start_line": 25,
105+
"reference_end_line": 148
106+
},
107+
{
108+
"qualified_name": "pipelex.plugins.openai.openai_img_gen_worker.OpenAIImgGenWorker",
109+
"reference_file": "pipelex/plugins/openai/openai_img_gen_worker.py",
110+
"reference_start_line": 22,
111+
"reference_end_line": 92
112+
}
113+
],
114+
"assigned_files": [
115+
"pipelex/plugins/openai",
116+
"pipelex/plugins/openai/__init__.py",
117+
"pipelex/plugins/openai/openai_llm_worker.py",
118+
"pipelex/plugins/openai/openai_llms.py",
119+
"pipelex/plugins/openai/openai_factory.py",
120+
"pipelex/plugins/openai/openai_func.py",
121+
"pipelex/plugins/openai/openai_img_gen_worker.py",
122+
"pipelex/plugins/openai/openai_img_gen_factory.py",
123+
"pipelex/plugins/openai/openai_img_gen_alt_worker.py",
124+
"pipelex/plugins/openai"
125+
],
126+
"can_expand": true
127+
},
128+
{
129+
"name": "Unclassified",
130+
"description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)",
131+
"referenced_source_code": [],
132+
"assigned_files": [
133+
"pipelex/cogt",
134+
"pipelex/cogt/__init__.py",
135+
"pipelex/cogt/config_cogt.py",
136+
"pipelex/cogt/exceptions.py",
137+
"pipelex/cogt/templating/__init__.py",
138+
"pipelex/cogt/templating/template_rendering.py",
139+
"pipelex/cogt/templating/template_preprocessor.py",
140+
"pipelex/cogt/templating/template_blueprint.py",
141+
"pipelex/cogt/templating/template_category.py",
142+
"pipelex/cogt/templating/templating_style.py",
143+
"pipelex/cogt/content_generation/__init__.py",
144+
"pipelex/cogt/content_generation/content_generator_dry.py",
145+
"pipelex/cogt/content_generation/assignment_models.py",
146+
"pipelex/cogt/content_generation/llm_generate.py",
147+
"pipelex/cogt/content_generation/templating_generate.py",
148+
"pipelex/cogt/content_generation/extract_generate.py",
149+
"pipelex/cogt/content_generation/content_generator_protocol.py",
150+
"pipelex/cogt/content_generation/content_generator.py",
151+
"pipelex/cogt/content_generation/img_gen_generate.py",
152+
"pipelex/cogt"
153+
],
154+
"can_expand": false
155+
}
156+
],
157+
"components_relations": [
158+
{
159+
"relation": "interacts with",
160+
"src_name": "ModelBackendManager",
161+
"dst_name": "LLMInterface"
162+
},
163+
{
164+
"relation": "interacts with",
165+
"src_name": "ModelBackendManager",
166+
"dst_name": "ImageGenerationInterface"
167+
},
168+
{
169+
"relation": "interacts with",
170+
"src_name": "ModelBackendManager",
171+
"dst_name": "OpenAIIntegration"
172+
},
173+
{
174+
"relation": "dispatches to",
175+
"src_name": "LLMInterface",
176+
"dst_name": "OpenAIIntegration"
177+
},
178+
{
179+
"relation": "dispatches to",
180+
"src_name": "ImageGenerationInterface",
181+
"dst_name": "OpenAIIntegration"
182+
},
183+
{
184+
"relation": "implements",
185+
"src_name": "OpenAIIntegration",
186+
"dst_name": "LLMInterface"
187+
},
188+
{
189+
"relation": "implements",
190+
"src_name": "OpenAIIntegration",
191+
"dst_name": "ImageGenerationInterface"
192+
}
193+
]
194+
}
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
```mermaid
2+
graph LR
3+
ModelBackendManager["ModelBackendManager"]
4+
LLMInterface["LLMInterface"]
5+
ImageGenerationInterface["ImageGenerationInterface"]
6+
OpenAIIntegration["OpenAIIntegration"]
7+
Unclassified["Unclassified"]
8+
ModelBackendManager -- "interacts with" --> LLMInterface
9+
ModelBackendManager -- "interacts with" --> ImageGenerationInterface
10+
ModelBackendManager -- "interacts with" --> OpenAIIntegration
11+
LLMInterface -- "dispatches to" --> OpenAIIntegration
12+
ImageGenerationInterface -- "dispatches to" --> OpenAIIntegration
13+
OpenAIIntegration -- "implements" --> LLMInterface
14+
OpenAIIntegration -- "implements" --> ImageGenerationInterface
15+
```
16+
17+
[![CodeBoarding](https://img.shields.io/badge/Generated%20by-CodeBoarding-9cf?style=flat-square)](https://github.com/CodeBoarding/CodeBoarding)[![Demo](https://img.shields.io/badge/Try%20our-Demo-blue?style=flat-square)](https://www.codeboarding.org/diagrams)[![Contact](https://img.shields.io/badge/Contact%20us%20-%20contact@codeboarding.org-lightgrey?style=flat-square)](mailto:contact@codeboarding.org)
18+
19+
## Details
20+
21+
The `pipelex` system leverages a flexible architecture for integrating various AI model backends. The `ModelBackendManager` serves as the central hub, abstracting the complexities of different AI providers. It interacts with standardized interfaces like `LLMInterface` for Large Language Models and `ImageGenerationInterface` for image generation, ensuring a consistent API for the rest of the system. Concrete implementations, such as `OpenAIIntegration`, provide the actual communication with external AI services, translating generic requests into provider-specific API calls and handling responses. This design allows for easy extension and interchangeability of AI backends, promoting modularity and adaptability within the `pipelex` ecosystem.
22+
23+
### ModelBackendManager
24+
This component is responsible for registering, configuring, and dynamically routing requests to various AI model backends. It acts as the central dispatcher, abstracting provider-specific details and presenting a unified interface to the rest of the `pipelex` system. It ensures that workflows can seamlessly switch between or utilize different AI providers without direct knowledge of their underlying APIs.
25+
26+
27+
**Related Classes/Methods**:
28+
29+
- <a href="https://github.com/Pipelex/pipelex/blob/main/.codeboardingpipelex/cogt/model_backends/backend.py#L9-L28" target="_blank" rel="noopener noreferrer">`pipelex.cogt.model_backends.backend.InferenceBackend`:9-28</a>
30+
31+
32+
### LLMInterface
33+
Defines a standardized API for interacting with Large Language Models. This interface specifies methods for common NLP tasks such as text generation, summarization, and embeddings, ensuring consistency across different LLM implementations.
34+
35+
36+
**Related Classes/Methods**:
37+
38+
- <a href="https://github.com/Pipelex/pipelex/blob/main/.codeboardingpipelex/cogt/llm/llm_worker_abstract.py#L18-L129" target="_blank" rel="noopener noreferrer">`pipelex.cogt.llm.llm_worker_abstract.LLMWorkerAbstract`:18-129</a>
39+
40+
41+
### ImageGenerationInterface
42+
Provides a standardized API for generating images based on textual prompts or other inputs. Similar to the `LLMInterface`, it ensures a consistent way for the `pipelex` system to request image generation from various providers.
43+
44+
45+
**Related Classes/Methods**:
46+
47+
- <a href="https://github.com/Pipelex/pipelex/blob/main/.codeboardingpipelex/cogt/img_gen/img_gen_worker_abstract.py#L14-L106" target="_blank" rel="noopener noreferrer">`pipelex.cogt.img_gen.img_gen_worker_abstract.ImgGenWorkerAbstract`:14-106</a>
48+
49+
50+
### OpenAIIntegration
51+
This component handles the direct communication and API calls to the OpenAI platform. It translates generic requests from the `LLMInterface` and `ImageGenerationInterface` into OpenAI-specific API calls and processes the responses, acting as a concrete implementation for OpenAI services.
52+
53+
54+
**Related Classes/Methods**:
55+
56+
- <a href="https://github.com/Pipelex/pipelex/blob/main/.codeboardingpipelex/plugins/openai/openai_llm_worker.py#L25-L148" target="_blank" rel="noopener noreferrer">`pipelex.plugins.openai.openai_llm_worker.OpenAILLMWorker`:25-148</a>
57+
- <a href="https://github.com/Pipelex/pipelex/blob/main/.codeboardingpipelex/plugins/openai/openai_img_gen_worker.py#L22-L92" target="_blank" rel="noopener noreferrer">`pipelex.plugins.openai.openai_img_gen_worker.OpenAIImgGenWorker`:22-92</a>
58+
59+
60+
### Unclassified
61+
Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)
62+
63+
64+
**Related Classes/Methods**: _None_
65+
66+
67+
68+
### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq)

0 commit comments

Comments
 (0)