From 30603ec3a8d0fc252bd1e1d730385c5156ed7cd0 Mon Sep 17 00:00:00 2001 From: ivanmilevtues Date: Fri, 25 Jul 2025 21:25:46 -0700 Subject: [PATCH 01/29] Added workflow and docs --- .github/workflows/codeboarding-docs.yaml | 177 +++++++++++++++++++++++ README.md | 5 + 2 files changed, 182 insertions(+) create mode 100644 .github/workflows/codeboarding-docs.yaml diff --git a/.github/workflows/codeboarding-docs.yaml b/.github/workflows/codeboarding-docs.yaml new file mode 100644 index 0000000..010392c --- /dev/null +++ b/.github/workflows/codeboarding-docs.yaml @@ -0,0 +1,177 @@ +name: CodeBoarding Documentation update workflow + +on: + schedule: + - cron: '0 20 * * 6' # Every Saturday at 8:00 PM UTC + workflow_dispatch: + inputs: + repository_url: + description: 'Repository URL to test with' + required: false + default: 'https://github.com/friendliai/friendli-python' + type: string + source_branch: + description: 'Source branch for generation' + required: false + default: 'main' + type: string + target_branch: + description: 'Target branch for pull request' + required: false + default: 'main' + type: string + output_format: + description: 'Output format for documentation' + required: false + default: '.md' + type: choice + options: + - '.mdx' + - '.md' + - '.rst' + output_directory: + description: 'Output directory for documentation files' + required: false + default: '.codeboarding' + type: string + +jobs: + update-docs-action-usage: + runs-on: ubuntu-latest + timeout-minutes: 45 + permissions: + contents: write + pull-requests: write + steps: + - name: Checkout repository + uses: actions/checkout@v4 + with: + token: ${{ secrets.GITHUB_TOKEN }} + fetch-depth: 0 # Required to access branch history + + # Determine branches based on context + - name: Set branch variables + id: set-branches + run: | + if [ "${{ github.event_name }}" = "pull_request" ]; then + echo "source_branch=${{ github.head_ref }}" >> $GITHUB_OUTPUT + echo "target_branch=${{ github.base_ref }}" >> $GITHUB_OUTPUT + elif [ "${{ github.event.inputs.source_branch }}" != "" ] && [ "${{ github.event.inputs.target_branch }}" != "" ]; then + echo "source_branch=${{ github.event.inputs.source_branch }}" >> $GITHUB_OUTPUT + echo "target_branch=${{ github.event.inputs.target_branch }}" >> $GITHUB_OUTPUT + else + echo "source_branch=main" >> $GITHUB_OUTPUT + echo "target_branch=main" >> $GITHUB_OUTPUT + fi + + - name: Fetch CodeBoarding Documentation + timeout-minutes: 30 + id: codeboarding + uses: CodeBoarding/CodeBoarding-GHAction@0.1.2 + with: + repository_url: ${{ github.event.inputs.repository_url || github.server_url }}/${{ github.repository }} + source_branch: ${{ steps.set-branches.outputs.source_branch }} + target_branch: ${{ steps.set-branches.outputs.target_branch }} + output_directory: ${{ github.event.inputs.output_directory || '.codeboarding' }} + output_format: ${{ github.event.inputs.output_format || '.md' }} + + - name: Display Action Results + run: | + echo "Documentation files created: ${{ steps.codeboarding.outputs.markdown_files_created }}" + echo "JSON files created: ${{ steps.codeboarding.outputs.json_files_created }}" + echo "Documentation directory: ${{ steps.codeboarding.outputs.output_directory }}" + echo "JSON directory: ${{ steps.codeboarding.outputs.json_directory }}" + echo "Has changes: ${{ steps.codeboarding.outputs.has_changes }}" + + # Check if we have any changes to commit + - name: Check for changes + id: git-changes + run: | + if [ -n "$(git status --porcelain)" ]; then + echo "has_git_changes=true" >> $GITHUB_OUTPUT + else + echo "has_git_changes=false" >> $GITHUB_OUTPUT + fi + + # Create docs/architecture directory and copy CodeBoarding files + - name: Copy CodeBoarding documentation to architecture folder + if: steps.git-changes.outputs.has_git_changes == 'true' && steps.codeboarding.outputs.has_changes == 'true' + run: | + # Create docs/architecture directory if it doesn't exist + mkdir -p docs/architecture + + # Create on_boarding.md if it doesn't exist + if [ ! -f "docs/architecture/on_boarding.md" ]; then + cat > docs/architecture/on_boarding.md << 'EOF' + # Friendli Python SDK - Architecture & Onboarding + + This section contains automatically generated documentation to help developers understand the codebase architecture and onboarding process. + + ## Generated Documentation + + The following documentation files are automatically generated by CodeBoarding to provide insights into the codebase: + + EOF + fi + + # Log the files found in the CodeBoarding directory + echo "📁 Scanning CodeBoarding directory for .md files..." + ls -la .codeboarding/ || echo "⚠️ CodeBoarding directory not found" + + # Copy all .md files from CodeBoarding to docs/architecture + copied_files_count=0 + + for file in .codeboarding/*.md; do + if [ -f "$file" ]; then + filename=$(basename "$file") + echo "✅ Copying: $filename to docs/architecture/" + cp "$file" "docs/architecture/$filename" + copied_files_count=$((copied_files_count + 1)) + + # Add reference to on_boarding.md + echo "- [$filename](./$filename)" >> docs/architecture/on_boarding.md + fi + done + + # Add timestamp to on_boarding.md + echo "" >> docs/architecture/on_boarding.md + echo "_Last updated: $(date -u '+%Y-%m-%d %H:%M:%S UTC')_" >> docs/architecture/on_boarding.md + + # Summary logging + echo "" + echo "📊 File copy summary:" + echo " - Total .md files copied: $copied_files_count" + echo " - Destination: docs/architecture/" + + # List final contents + if [ $copied_files_count -gt 0 ]; then + echo " - Files in destination:" + ls -la docs/architecture/*.md 2>/dev/null || echo " No .md files found in destination" + fi + + echo "CodeBoarding documentation copied to docs/architecture/" + + - name: Commit and push changes + if: steps.git-changes.outputs.has_git_changes == 'true' && steps.codeboarding.outputs.has_changes == 'true' + run: | + git config --local user.email "action@github.com" + git config --local user.name "GitHub Action" + git add . + git commit -m "docs: update codeboarding architecture documentation + + ## 📚 Architecture Documentation Update + This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. + + ### 📊 Summary + - Documentation files created/updated: ${{ steps.codeboarding.outputs.markdown_files_created }} + - JSON files created/updated: ${{ steps.codeboarding.outputs.json_files_created }} + - Documentation directory: ${{ steps.codeboarding.outputs.output_directory }}/ + - JSON directory: ${{ steps.codeboarding.outputs.json_directory }}/ + - Output format: ${{ github.event.inputs.output_format || '.md' }} + - Repository analyzed: ${{ github.server_url }}/${{ github.repository }} + - Destination: docs/architecture/ + + The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. + + 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow." + git push diff --git a/README.md b/README.md index 25223be..b1225a2 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,10 @@ When using Friendli Python SDK, you need to provide a Friendli Token for authent 5. Create a new Friendli Token by clicking the "Create token" button. 6. Copy the token and save it in a safe place. You will not be able to see this token again once the page is refreshed. +## Architecture & Development Onboarding + +For developers looking to understand the codebase architecture and get started with contributing to the Friendli Python SDK, please refer to our comprehensive [Architecture & Onboarding Guide](./docs/architecture/on_boarding.md). This documentation is automatically generated and maintained to provide up-to-date insights into the codebase structure, patterns, and development workflows. + @@ -24,6 +28,7 @@ When using Friendli Python SDK, you need to provide a Friendli Token for authent * [Friendli Python SDK](#friendli-python-sdk) * [Token Setup](#token-setup) + * [Architecture & Development Onboarding](#architecture--development-onboarding) * [SDK Installation](#sdk-installation) * [SDK Example Usage](#sdk-example-usage) * [Authentication](#authentication) From 27fb44c7574210fa86d30f07e3333dd9ca466d15 Mon Sep 17 00:00:00 2001 From: ivanmilevtues Date: Fri, 25 Jul 2025 21:49:40 -0700 Subject: [PATCH 02/29] Update in workflow --- .github/workflows/codeboarding-docs.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/codeboarding-docs.yaml b/.github/workflows/codeboarding-docs.yaml index 010392c..86cd411 100644 --- a/.github/workflows/codeboarding-docs.yaml +++ b/.github/workflows/codeboarding-docs.yaml @@ -69,7 +69,7 @@ jobs: id: codeboarding uses: CodeBoarding/CodeBoarding-GHAction@0.1.2 with: - repository_url: ${{ github.event.inputs.repository_url || github.server_url }}/${{ github.repository }} + repository_url: ${{ github.event.inputs.repository_url }} source_branch: ${{ steps.set-branches.outputs.source_branch }} target_branch: ${{ steps.set-branches.outputs.target_branch }} output_directory: ${{ github.event.inputs.output_directory || '.codeboarding' }} From 9593a515ae5e2249ce3c823bdd3c4cf92a6e45ae Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 26 Jul 2025 05:04:17 +0000 Subject: [PATCH 03/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 6 - JSON files created/updated: 7 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Data_Models_Error_Handling.json | 142 ++++++++++++ .codeboarding/Data_Models_Error_Handling.md | 78 +++++++ .../Friendli_Client_Public_API_.json | 166 ++++++++++++++ .codeboarding/Friendli_Client_Public_API_.md | 98 +++++++++ .codeboarding/Platform_Abstractions.json | 80 +++++++ .codeboarding/Platform_Abstractions.md | 50 +++++ .codeboarding/SDK_Core.json | 207 ++++++++++++++++++ .codeboarding/SDK_Core.md | 115 ++++++++++ .codeboarding/Service_Modules.json | 140 ++++++++++++ .codeboarding/Service_Modules.md | 76 +++++++ .codeboarding/analysis.json | 139 ++++++++++++ .codeboarding/codeboarding_version.json | 4 + .codeboarding/on_boarding.md | 88 ++++++++ .../Data_Models_Error_Handling.md | 78 +++++++ .../Friendli_Client_Public_API_.md | 98 +++++++++ docs/architecture/Platform_Abstractions.md | 50 +++++ docs/architecture/SDK_Core.md | 115 ++++++++++ docs/architecture/Service_Modules.md | 76 +++++++ docs/architecture/on_boarding.md | 91 ++++++++ 19 files changed, 1891 insertions(+) create mode 100644 .codeboarding/Data_Models_Error_Handling.json create mode 100644 .codeboarding/Data_Models_Error_Handling.md create mode 100644 .codeboarding/Friendli_Client_Public_API_.json create mode 100644 .codeboarding/Friendli_Client_Public_API_.md create mode 100644 .codeboarding/Platform_Abstractions.json create mode 100644 .codeboarding/Platform_Abstractions.md create mode 100644 .codeboarding/SDK_Core.json create mode 100644 .codeboarding/SDK_Core.md create mode 100644 .codeboarding/Service_Modules.json create mode 100644 .codeboarding/Service_Modules.md create mode 100644 .codeboarding/analysis.json create mode 100644 .codeboarding/codeboarding_version.json create mode 100644 .codeboarding/on_boarding.md create mode 100644 docs/architecture/Data_Models_Error_Handling.md create mode 100644 docs/architecture/Friendli_Client_Public_API_.md create mode 100644 docs/architecture/Platform_Abstractions.md create mode 100644 docs/architecture/SDK_Core.md create mode 100644 docs/architecture/Service_Modules.md create mode 100644 docs/architecture/on_boarding.md diff --git a/.codeboarding/Data_Models_Error_Handling.json b/.codeboarding/Data_Models_Error_Handling.json new file mode 100644 index 0000000..209474e --- /dev/null +++ b/.codeboarding/Data_Models_Error_Handling.json @@ -0,0 +1,142 @@ +{ + "description": "This analysis outlines the final component structure of the `friendli_core` SDK, detailing its five key components: Core Client, Service Modules, Data Models & Error Handling, Utility Functions, and Examples and Documentation. It describes each component's role, associated source files, and interactions within the SDK, providing a comprehensive overview of the system's architecture and interdependencies.", + "components": [ + { + "name": "Core Client", + "description": "The central entry point for the SDK, responsible for managing authentication, session handling, and dispatching requests to the appropriate service modules. It provides the primary interface for users to interact with the Friendli AI platform.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.client", + "reference_file": "friendli_core.client.py", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": true + }, + { + "name": "Service Modules", + "description": "Encapsulate specific API functionalities (e.g., chat, completions, image generation, audio processing). Each module provides high-level methods for its domain, abstracting the underlying RESTful API calls and handling domain-specific logic.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.chat", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.completions", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.image", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.audio", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/audio.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Data Models & Error Handling", + "description": "Defines standardized data structures for all API requests and responses, ensuring consistent data representation across the SDK. This component also provides a comprehensive set of error types, facilitating robust and standardized error reporting from the Friendli AI platform.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.models", + "reference_file": "friendli_core.models.py", + "reference_start_line": 1, + "reference_end_line": 1 + }, + { + "qualified_name": "friendli_core.errors", + "reference_file": "friendli_core.errors.py", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": true + }, + { + "name": "Utility Functions", + "description": "Provides common helper functions for SDK-wide tasks such as JSON serialization/deserialization, parameter validation, configuration loading, and other reusable logic that supports the core functionalities.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.utils", + "reference_file": "friendli_core.utils.py", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": false + }, + { + "name": "Examples and Documentation", + "description": "Comprises practical code examples demonstrating how to effectively use the SDK's functionalities and comprehensive documentation (API references, guides) to assist developers in integrating and utilizing the Friendli AI platform.", + "referenced_source_code": [ + { + "qualified_name": "examples", + "reference_file": "examples/", + "reference_start_line": 1, + "reference_end_line": 1 + }, + { + "qualified_name": "docs", + "reference_file": "docs/", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": false + } + ], + "components_relations": [ + { + "relation": "uses", + "src_name": "Core Client", + "dst_name": "Service Modules" + }, + { + "relation": "uses", + "src_name": "Core Client", + "dst_name": "Data Models & Error Handling" + }, + { + "relation": "uses", + "src_name": "Core Client", + "dst_name": "Utility Functions" + }, + { + "relation": "utilizes", + "src_name": "Service Modules", + "dst_name": "Data Models & Error Handling" + }, + { + "relation": "uses", + "src_name": "Service Modules", + "dst_name": "Utility Functions" + }, + { + "relation": "showcases usage of", + "src_name": "Examples and Documentation", + "dst_name": "Core Client" + }, + { + "relation": "showcases usage of", + "src_name": "Examples and Documentation", + "dst_name": "Service Modules" + }, + { + "relation": "relies on", + "src_name": "Examples and Documentation", + "dst_name": "Data Models & Error Handling" + } + ] +} diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md new file mode 100644 index 0000000..6132c01 --- /dev/null +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -0,0 +1,78 @@ +```mermaid +graph LR + Core_Client["Core Client"] + Service_Modules["Service Modules"] + Data_Models_Error_Handling["Data Models & Error Handling"] + Utility_Functions["Utility Functions"] + Examples_and_Documentation["Examples and Documentation"] + Core_Client -- "uses" --> Service_Modules + Core_Client -- "uses" --> Data_Models_Error_Handling + Core_Client -- "uses" --> Utility_Functions + Service_Modules -- "utilizes" --> Data_Models_Error_Handling + Service_Modules -- "uses" --> Utility_Functions + Examples_and_Documentation -- "showcases usage of" --> Core_Client + Examples_and_Documentation -- "showcases usage of" --> Service_Modules + Examples_and_Documentation -- "relies on" --> Data_Models_Error_Handling + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) + +## Details + +This analysis outlines the final component structure of the `friendli_core` SDK, detailing its five key components: Core Client, Service Modules, Data Models & Error Handling, Utility Functions, and Examples and Documentation. It describes each component's role, associated source files, and interactions within the SDK, providing a comprehensive overview of the system's architecture and interdependencies. + +### Core Client +The central entry point for the SDK, responsible for managing authentication, session handling, and dispatching requests to the appropriate service modules. It provides the primary interface for users to interact with the Friendli AI platform. + + +**Related Classes/Methods**: + +- `friendli_core.client` (1:1) + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate specific API functionalities (e.g., chat, completions, image generation, audio processing). Each module provides high-level methods for its domain, abstracting the underlying RESTful API calls and handling domain-specific logic. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.image` +- `friendli_core.audio` + + +### Data Models & Error Handling [[Expand]](./Data_Models_Error_Handling.md) +Defines standardized data structures for all API requests and responses, ensuring consistent data representation across the SDK. This component also provides a comprehensive set of error types, facilitating robust and standardized error reporting from the Friendli AI platform. + + +**Related Classes/Methods**: + +- `friendli_core.models` (1:1) +- `friendli_core.errors` (1:1) + + +### Utility Functions +Provides common helper functions for SDK-wide tasks such as JSON serialization/deserialization, parameter validation, configuration loading, and other reusable logic that supports the core functionalities. + + +**Related Classes/Methods**: + +- `friendli_core.utils` (1:1) + + +### Examples and Documentation +Comprises practical code examples demonstrating how to effectively use the SDK's functionalities and comprehensive documentation (API references, guides) to assist developers in integrating and utilizing the Friendli AI platform. + + +**Related Classes/Methods**: + +- `examples` (1:1) +- `docs` (1:1) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/Friendli_Client_Public_API_.json b/.codeboarding/Friendli_Client_Public_API_.json new file mode 100644 index 0000000..6dc6402 --- /dev/null +++ b/.codeboarding/Friendli_Client_Public_API_.json @@ -0,0 +1,166 @@ +{ + "description": "Final Component Overview for the `Friendli Client (Public API)` subsystem, structured according to Client-side SDK patterns.", + "components": [ + { + "name": "Core Client (Public API)", + "description": "The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations. It acts as the orchestrator, delegating requests to specific service modules.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.sdk", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/sdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Service Modules", + "description": "Encapsulate the logic for interacting with specific API endpoints (e.g., chat, completions, images, audio). Each module handles the construction of requests, serialization of data models, and deserialization of responses for its domain.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.chat", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.completions", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.images", + "reference_file": "friendli_core.images", + "reference_start_line": 1, + "reference_end_line": 1 + }, + { + "qualified_name": "friendli_core.audio", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/audio.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Data Models", + "description": "Define the structure of data exchanged with the Friendli AI platform, including request bodies, response objects, and various parameters. Ensures type safety and consistency across all API interactions within the SDK.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.models", + "reference_file": "friendli_core.models", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": false + }, + { + "name": "HTTP Client/Transport Layer", + "description": "Handles the low-level HTTP communication with the Friendli AI platform. This includes managing connections, sending requests, receiving responses, and abstracting away network-level concerns like retries and timeouts.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.http_client", + "reference_file": "friendli_core.http_client", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": true + }, + { + "name": "Error Handling", + "description": "Manages and standardizes error responses from both the API and the network layer. It provides custom exception classes and mechanisms for users to gracefully handle API-related issues and network errors, ensuring a consistent error reporting experience.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.errors", + "reference_file": "friendli_core.errors", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": true + }, + { + "name": "Configuration Management", + "description": "Centralizes and manages SDK-wide configuration settings, such as API keys, base URLs, default timeouts, and retry policies. It provides a consistent and accessible way to configure the SDK's behavior.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.config", + "reference_file": "friendli_core.config", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": false + }, + { + "name": "Utility Functions", + "description": "Provides common helper functions and reusable functionalities that support various parts of the SDK, such as authentication token management, data validation, or specific data transformations that are not tied to a particular API domain.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.utils", + "reference_file": "friendli_core.utils", + "reference_start_line": 1, + "reference_end_line": 1 + } + ], + "can_expand": true + } + ], + "components_relations": [ + { + "relation": "uses", + "src_name": "Core Client (Public API)", + "dst_name": "Service Modules" + }, + { + "relation": "uses", + "src_name": "Core Client (Public API)", + "dst_name": "Configuration Management" + }, + { + "relation": "uses", + "src_name": "Core Client (Public API)", + "dst_name": "Data Models" + }, + { + "relation": "uses", + "src_name": "Core Client (Public API)", + "dst_name": "Utility Functions" + }, + { + "relation": "uses", + "src_name": "Service Modules", + "dst_name": "HTTP Client/Transport Layer" + }, + { + "relation": "uses", + "src_name": "Service Modules", + "dst_name": "Data Models" + }, + { + "relation": "uses", + "src_name": "Service Modules", + "dst_name": "Error Handling" + }, + { + "relation": "uses", + "src_name": "Service Modules", + "dst_name": "Utility Functions" + }, + { + "relation": "uses", + "src_name": "HTTP Client/Transport Layer", + "dst_name": "Configuration Management" + }, + { + "relation": "uses", + "src_name": "HTTP Client/Transport Layer", + "dst_name": "Error Handling" + } + ] +} diff --git a/.codeboarding/Friendli_Client_Public_API_.md b/.codeboarding/Friendli_Client_Public_API_.md new file mode 100644 index 0000000..d0fd9c6 --- /dev/null +++ b/.codeboarding/Friendli_Client_Public_API_.md @@ -0,0 +1,98 @@ +```mermaid +graph LR + Core_Client_Public_API_["Core Client (Public API)"] + Service_Modules["Service Modules"] + Data_Models["Data Models"] + HTTP_Client_Transport_Layer["HTTP Client/Transport Layer"] + Error_Handling["Error Handling"] + Configuration_Management["Configuration Management"] + Utility_Functions["Utility Functions"] + Core_Client_Public_API_ -- "uses" --> Service_Modules + Core_Client_Public_API_ -- "uses" --> Configuration_Management + Core_Client_Public_API_ -- "uses" --> Data_Models + Core_Client_Public_API_ -- "uses" --> Utility_Functions + Service_Modules -- "uses" --> HTTP_Client_Transport_Layer + Service_Modules -- "uses" --> Data_Models + Service_Modules -- "uses" --> Error_Handling + Service_Modules -- "uses" --> Utility_Functions + HTTP_Client_Transport_Layer -- "uses" --> Configuration_Management + HTTP_Client_Transport_Layer -- "uses" --> Error_Handling + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) + +## Details + +Final Component Overview for the `Friendli Client (Public API)` subsystem, structured according to Client-side SDK patterns. + +### Core Client (Public API) +The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations. It acts as the orchestrator, delegating requests to specific service modules. + + +**Related Classes/Methods**: + +- `friendli_core.sdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate the logic for interacting with specific API endpoints (e.g., chat, completions, images, audio). Each module handles the construction of requests, serialization of data models, and deserialization of responses for its domain. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.images` (1:1) +- `friendli_core.audio` + + +### Data Models +Define the structure of data exchanged with the Friendli AI platform, including request bodies, response objects, and various parameters. Ensures type safety and consistency across all API interactions within the SDK. + + +**Related Classes/Methods**: + +- `friendli_core.models` (1:1) + + +### HTTP Client/Transport Layer +Handles the low-level HTTP communication with the Friendli AI platform. This includes managing connections, sending requests, receiving responses, and abstracting away network-level concerns like retries and timeouts. + + +**Related Classes/Methods**: + +- `friendli_core.http_client` (1:1) + + +### Error Handling [[Expand]](./Error_Handling.md) +Manages and standardizes error responses from both the API and the network layer. It provides custom exception classes and mechanisms for users to gracefully handle API-related issues and network errors, ensuring a consistent error reporting experience. + + +**Related Classes/Methods**: + +- `friendli_core.errors` (1:1) + + +### Configuration Management +Centralizes and manages SDK-wide configuration settings, such as API keys, base URLs, default timeouts, and retry policies. It provides a consistent and accessible way to configure the SDK's behavior. + + +**Related Classes/Methods**: + +- `friendli_core.config` (1:1) + + +### Utility Functions +Provides common helper functions and reusable functionalities that support various parts of the SDK, such as authentication token management, data validation, or specific data transformations that are not tied to a particular API domain. + + +**Related Classes/Methods**: + +- `friendli_core.utils` (1:1) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/Platform_Abstractions.json b/.codeboarding/Platform_Abstractions.json new file mode 100644 index 0000000..7af4799 --- /dev/null +++ b/.codeboarding/Platform_Abstractions.json @@ -0,0 +1,80 @@ +{ + "description": "Abstract Components Overview", + "components": [ + { + "name": "Platform Abstractions", + "description": "Defines the foundational base structures and interfaces that enable the SDK to adapt its behavior to various operational modes (e.g., dedicated, serverless) of the Friendli platform. It provides the abstract contracts for interacting with different deployment types.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.basesdk:BaseSDK", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", + "reference_start_line": 19, + "reference_end_line": 106 + } + ], + "can_expand": true + }, + { + "name": "Dedicated Client", + "description": "A concrete implementation of the `Platform Abstractions` tailored specifically for interacting with the Friendli platform in a \"dedicated\" operational mode. It provides the specific logic and configurations required for this environment.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.dedicated:BaseDedicated", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", + "reference_start_line": 24, + "reference_end_line": 32 + }, + { + "qualified_name": "friendli_core.dedicated:SyncDedicated", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", + "reference_start_line": 35, + "reference_end_line": 49 + }, + { + "qualified_name": "friendli_core.dedicated:AsyncDedicated", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", + "reference_start_line": 52, + "reference_end_line": 66 + } + ], + "can_expand": true + }, + { + "name": "Serverless Client", + "description": "A concrete implementation of the `Platform Abstractions` designed for interacting with the Friendli platform in a \"serverless\" operational mode. It encapsulates the specific logic and configurations for this environment.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.serverless:BaseServerless", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py", + "reference_start_line": 24, + "reference_end_line": 32 + }, + { + "qualified_name": "friendli_core.serverless:SyncServerless", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py", + "reference_start_line": 35, + "reference_end_line": 49 + }, + { + "qualified_name": "friendli_core.serverless:AsyncServerless", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py", + "reference_start_line": 52, + "reference_end_line": 68 + } + ], + "can_expand": true + } + ], + "components_relations": [ + { + "relation": "implements", + "src_name": "Dedicated Client", + "dst_name": "Platform Abstractions" + }, + { + "relation": "implements", + "src_name": "Serverless Client", + "dst_name": "Platform Abstractions" + } + ] +} diff --git a/.codeboarding/Platform_Abstractions.md b/.codeboarding/Platform_Abstractions.md new file mode 100644 index 0000000..0dc9c08 --- /dev/null +++ b/.codeboarding/Platform_Abstractions.md @@ -0,0 +1,50 @@ +```mermaid +graph LR + Platform_Abstractions["Platform Abstractions"] + Dedicated_Client["Dedicated Client"] + Serverless_Client["Serverless Client"] + Dedicated_Client -- "implements" --> Platform_Abstractions + Serverless_Client -- "implements" --> Platform_Abstractions + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) + +## Details + +Abstract Components Overview + +### Platform Abstractions [[Expand]](./Platform_Abstractions.md) +Defines the foundational base structures and interfaces that enable the SDK to adapt its behavior to various operational modes (e.g., dedicated, serverless) of the Friendli platform. It provides the abstract contracts for interacting with different deployment types. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk:BaseSDK` (19:106) + + +### Dedicated Client +A concrete implementation of the `Platform Abstractions` tailored specifically for interacting with the Friendli platform in a "dedicated" operational mode. It provides the specific logic and configurations required for this environment. + + +**Related Classes/Methods**: + +- `friendli_core.dedicated:BaseDedicated` (24:32) +- `friendli_core.dedicated:SyncDedicated` (35:49) +- `friendli_core.dedicated:AsyncDedicated` (52:66) + + +### Serverless Client +A concrete implementation of the `Platform Abstractions` designed for interacting with the Friendli platform in a "serverless" operational mode. It encapsulates the specific logic and configurations for this environment. + + +**Related Classes/Methods**: + +- `friendli_core.serverless:BaseServerless` (24:32) +- `friendli_core.serverless:SyncServerless` (35:49) +- `friendli_core.serverless:AsyncServerless` (52:68) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/SDK_Core.json b/.codeboarding/SDK_Core.json new file mode 100644 index 0000000..5c06704 --- /dev/null +++ b/.codeboarding/SDK_Core.json @@ -0,0 +1,207 @@ +{ + "description": "This section synthesizes the architectural components of the Friendli AI Python SDK, focusing on the `SDK Core` and its interactions within a client-side SDK pattern.", + "components": [ + { + "name": "SDK Core", + "description": "The foundational layer and central orchestrator of the SDK. It encapsulates the fundamental logic for API communication, request/response processing, and integrates core SDK abstractions. It provides the base classes (`BaseSDK`, `AsyncSDK`, `SyncSDK`) from which other service modules inherit, ensuring consistent interaction patterns and extensibility. It also manages global settings and extensibility points.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.basesdk", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Service Modules", + "description": "These modules encapsulate specific API functionalities (e.g., Chat, Completions, Image, Dataset). They extend the `SDK Core`'s base classes to provide high-level, domain-specific methods for interacting with different parts of the Friendli AI platform.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.chat", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.completions", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Data Models", + "description": "Defines the structured data objects (e.g., request bodies, response objects) used for communication with the Friendli AI platform. These models ensure type safety, consistency, and ease of use when exchanging data with the API.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.models", + "reference_file": "friendli_core/models.py", + "reference_start_line": 0, + "reference_end_line": 0 + } + ], + "can_expand": true + }, + { + "name": "Error Handling", + "description": "Manages and standardizes error responses originating from the API or internal SDK operations. It provides custom exceptions and robust error handling mechanisms, allowing developers to gracefully manage and respond to issues.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.errors", + "reference_file": "friendli_core/errors.py", + "reference_start_line": 0, + "reference_end_line": 0 + } + ], + "can_expand": false + }, + { + "name": "SDK Configuration", + "description": "Manages global settings and parameters for the SDK, such as API keys, base URLs, timeouts, and other configurable options. It provides a centralized mechanism for developers to customize the SDK's behavior.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.config", + "reference_file": "friendli_core/config.py", + "reference_start_line": 0, + "reference_end_line": 0 + } + ], + "can_expand": true + }, + { + "name": "Utility Functions", + "description": "Provides a collection of helper functions for common tasks that support the SDK's overall functionality. This includes operations like authentication, data serialization/deserialization, and other general-purpose utilities.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.utils", + "reference_file": "friendli_core/utils.py", + "reference_start_line": 0, + "reference_end_line": 0 + } + ], + "can_expand": true + }, + { + "name": "Asynchronous/Synchronous Adapters", + "description": "Provides distinct interfaces and implementations for both asynchronous (non-blocking) and synchronous (blocking) API calls. This allows developers to choose the appropriate execution model based on their application's architecture and performance requirements.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.basesdk", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Extensibility (Hooks)", + "description": "Offers mechanisms for extending SDK behavior through hooks or context objects (e.g., `HookContext`). This allows developers to inject custom logic at various points in the request/response lifecycle without altering the core SDK code.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.basesdk", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + } + ], + "components_relations": [ + { + "relation": "provides base classes to", + "src_name": "SDK Core", + "dst_name": "Service Modules" + }, + { + "relation": "utilizes", + "src_name": "Service Modules", + "dst_name": "SDK Core" + }, + { + "relation": "serializes/deserializes", + "src_name": "SDK Core", + "dst_name": "Data Models" + }, + { + "relation": "defines format for", + "src_name": "Data Models", + "dst_name": "SDK Core" + }, + { + "relation": "raises exceptions from", + "src_name": "SDK Core", + "dst_name": "Error Handling" + }, + { + "relation": "defines exceptions for", + "src_name": "Error Handling", + "dst_name": "SDK Core" + }, + { + "relation": "consumes settings from", + "src_name": "SDK Core", + "dst_name": "SDK Configuration" + }, + { + "relation": "provides parameters to", + "src_name": "SDK Configuration", + "dst_name": "SDK Core" + }, + { + "relation": "defines interface for", + "src_name": "SDK Core", + "dst_name": "Asynchronous/Synchronous Adapters" + }, + { + "relation": "provides execution paths for", + "src_name": "Asynchronous/Synchronous Adapters", + "dst_name": "SDK Core" + }, + { + "relation": "invokes", + "src_name": "SDK Core", + "dst_name": "Extensibility (Hooks)" + }, + { + "relation": "modifies behavior of", + "src_name": "Extensibility (Hooks)", + "dst_name": "SDK Core" + }, + { + "relation": "constructs requests with", + "src_name": "Service Modules", + "dst_name": "Data Models" + }, + { + "relation": "returns responses as", + "src_name": "Service Modules", + "dst_name": "Data Models" + }, + { + "relation": "handles exceptions from", + "src_name": "Service Modules", + "dst_name": "Error Handling" + }, + { + "relation": "defines error types for", + "src_name": "Error Handling", + "dst_name": "Service Modules" + }, + { + "relation": "provides helpers to", + "src_name": "Utility Functions", + "dst_name": "SDK Core" + }, + { + "relation": "provides helpers to", + "src_name": "Utility Functions", + "dst_name": "Service Modules" + } + ] +} diff --git a/.codeboarding/SDK_Core.md b/.codeboarding/SDK_Core.md new file mode 100644 index 0000000..0aa48b1 --- /dev/null +++ b/.codeboarding/SDK_Core.md @@ -0,0 +1,115 @@ +```mermaid +graph LR + SDK_Core["SDK Core"] + Service_Modules["Service Modules"] + Data_Models["Data Models"] + Error_Handling["Error Handling"] + SDK_Configuration["SDK Configuration"] + Utility_Functions["Utility Functions"] + Asynchronous_Synchronous_Adapters["Asynchronous/Synchronous Adapters"] + Extensibility_Hooks_["Extensibility (Hooks)"] + SDK_Core -- "provides base classes to" --> Service_Modules + Service_Modules -- "utilizes" --> SDK_Core + SDK_Core -- "serializes/deserializes" --> Data_Models + Data_Models -- "defines format for" --> SDK_Core + SDK_Core -- "raises exceptions from" --> Error_Handling + Error_Handling -- "defines exceptions for" --> SDK_Core + SDK_Core -- "consumes settings from" --> SDK_Configuration + SDK_Configuration -- "provides parameters to" --> SDK_Core + SDK_Core -- "defines interface for" --> Asynchronous_Synchronous_Adapters + Asynchronous_Synchronous_Adapters -- "provides execution paths for" --> SDK_Core + SDK_Core -- "invokes" --> Extensibility_Hooks_ + Extensibility_Hooks_ -- "modifies behavior of" --> SDK_Core + Service_Modules -- "constructs requests with" --> Data_Models + Service_Modules -- "returns responses as" --> Data_Models + Service_Modules -- "handles exceptions from" --> Error_Handling + Error_Handling -- "defines error types for" --> Service_Modules + Utility_Functions -- "provides helpers to" --> SDK_Core + Utility_Functions -- "provides helpers to" --> Service_Modules + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) + +## Details + +This section synthesizes the architectural components of the Friendli AI Python SDK, focusing on the `SDK Core` and its interactions within a client-side SDK pattern. + +### SDK Core [[Expand]](./SDK_Core.md) +The foundational layer and central orchestrator of the SDK. It encapsulates the fundamental logic for API communication, request/response processing, and integrates core SDK abstractions. It provides the base classes (`BaseSDK`, `AsyncSDK`, `SyncSDK`) from which other service modules inherit, ensuring consistent interaction patterns and extensibility. It also manages global settings and extensibility points. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +These modules encapsulate specific API functionalities (e.g., Chat, Completions, Image, Dataset). They extend the `SDK Core`'s base classes to provide high-level, domain-specific methods for interacting with different parts of the Friendli AI platform. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` + + +### Data Models +Defines the structured data objects (e.g., request bodies, response objects) used for communication with the Friendli AI platform. These models ensure type safety, consistency, and ease of use when exchanging data with the API. + + +**Related Classes/Methods**: + +- `friendli_core.models` + + +### Error Handling [[Expand]](./Error_Handling.md) +Manages and standardizes error responses originating from the API or internal SDK operations. It provides custom exceptions and robust error handling mechanisms, allowing developers to gracefully manage and respond to issues. + + +**Related Classes/Methods**: + +- `friendli_core.errors` + + +### SDK Configuration +Manages global settings and parameters for the SDK, such as API keys, base URLs, timeouts, and other configurable options. It provides a centralized mechanism for developers to customize the SDK's behavior. + + +**Related Classes/Methods**: + +- `friendli_core.config` + + +### Utility Functions +Provides a collection of helper functions for common tasks that support the SDK's overall functionality. This includes operations like authentication, data serialization/deserialization, and other general-purpose utilities. + + +**Related Classes/Methods**: + +- `friendli_core.utils` + + +### Asynchronous/Synchronous Adapters +Provides distinct interfaces and implementations for both asynchronous (non-blocking) and synchronous (blocking) API calls. This allows developers to choose the appropriate execution model based on their application's architecture and performance requirements. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Extensibility (Hooks) +Offers mechanisms for extending SDK behavior through hooks or context objects (e.g., `HookContext`). This allows developers to inject custom logic at various points in the request/response lifecycle without altering the core SDK code. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/Service_Modules.json b/.codeboarding/Service_Modules.json new file mode 100644 index 0000000..349839b --- /dev/null +++ b/.codeboarding/Service_Modules.json @@ -0,0 +1,140 @@ +{ + "description": "These components are chosen based on their fundamental architectural importance in a Client-side SDK. The `Service Modules` are the primary interface for users, encapsulating domain logic. The `Security Utility` is essential for authentication, a core cross-cutting concern. `JSON Unmarshalling Utility` and `Event Streaming Utility` are vital for handling diverse API response formats. Finally, `Hook Context Management` provides the necessary extensibility, aligning with the \"Extensibility\" principle mentioned in the project context. This set of components provides a clear, modular, and functional breakdown of the SDK's core responsibilities.", + "components": [ + { + "name": "Service Modules", + "description": "These modules encapsulate the core API domain logic for specific functionalities like Chat, Completions, Dataset management, and Image processing. They provide high-level, domain-specific methods that abstract the underlying API interactions, supporting both asynchronous and synchronous operations. This component is central to the SDK's usability, offering a clear interface for developers to interact with different parts of the Friendli API.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.chat.SyncChat", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "reference_start_line": 18, + "reference_end_line": 372 + }, + { + "qualified_name": "friendli_core.chat.AsyncChat", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "reference_start_line": 375, + "reference_end_line": 729 + }, + { + "qualified_name": "friendli_core.completions.SyncCompletions", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "reference_start_line": 18, + "reference_end_line": 194 + }, + { + "qualified_name": "friendli_core.completions.AsyncCompletions", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "reference_start_line": 197, + "reference_end_line": 373 + }, + { + "qualified_name": "friendli_core.dataset.SyncDataset", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", + "reference_start_line": 19, + "reference_end_line": 1528 + }, + { + "qualified_name": "friendli_core.dataset.AsyncDataset", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", + "reference_start_line": 1531, + "reference_end_line": 3040 + }, + { + "qualified_name": "friendli_core.image.SyncImage", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", + "reference_start_line": 18, + "reference_end_line": 118 + }, + { + "qualified_name": "friendli_core.image.AsyncImage", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", + "reference_start_line": 121, + "reference_end_line": 221 + } + ], + "can_expand": true + }, + { + "name": "Security Utility", + "description": "Responsible for securely retrieving and managing API credentials, typically from environment variables or other configuration sources. This component ensures that API requests are properly authenticated.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.utils.security.get_security_from_env", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/utils/security.py", + "reference_start_line": 57, + "reference_end_line": 69 + } + ], + "can_expand": false + }, + { + "name": "JSON Unmarshalling Utility", + "description": "Handles the deserialization of JSON responses received from the Friendli API into structured Python objects. This component is crucial for converting raw API data into usable formats within the SDK.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.utils.unmarshal_json_response.unmarshal_json_response", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/utils/unmarshal_json_response.py", + "reference_start_line": 11, + "reference_end_line": 24 + } + ], + "can_expand": false + }, + { + "name": "Event Streaming Utility", + "description": "Provides mechanisms for processing and managing streaming responses from the API, particularly for operations that return continuous data streams (e.g., chat completions). It abstracts the complexities of handling server-sent events or similar streaming protocols.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.utils.eventstreaming.EventStream", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/utils/eventstreaming.py", + "reference_start_line": 19, + "reference_end_line": 42 + }, + { + "qualified_name": "friendli_core.utils.eventstreaming.EventStreamAsync", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/utils/eventstreaming.py", + "reference_start_line": 45, + "reference_end_line": 68 + } + ], + "can_expand": false + }, + { + "name": "Hook Context Management", + "description": "Manages an extensibility mechanism that allows developers to inject custom logic (hooks) at various points during the API interaction lifecycle. This component supports the SDK's extensibility, enabling custom pre-processing, post-processing, or error handling.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.types.HookContext", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", + "reference_start_line": 11, + "reference_end_line": 30 + } + ], + "can_expand": true + } + ], + "components_relations": [ + { + "relation": "calls", + "src_name": "Service Modules", + "dst_name": "Security Utility" + }, + { + "relation": "invokes", + "src_name": "Service Modules", + "dst_name": "JSON Unmarshalling Utility" + }, + { + "relation": "interacts with", + "src_name": "Service Modules", + "dst_name": "Event Streaming Utility" + }, + { + "relation": "utilizes", + "src_name": "Service Modules", + "dst_name": "Hook Context Management" + } + ] +} diff --git a/.codeboarding/Service_Modules.md b/.codeboarding/Service_Modules.md new file mode 100644 index 0000000..3a387b3 --- /dev/null +++ b/.codeboarding/Service_Modules.md @@ -0,0 +1,76 @@ +```mermaid +graph LR + Service_Modules["Service Modules"] + Security_Utility["Security Utility"] + JSON_Unmarshalling_Utility["JSON Unmarshalling Utility"] + Event_Streaming_Utility["Event Streaming Utility"] + Hook_Context_Management["Hook Context Management"] + Service_Modules -- "calls" --> Security_Utility + Service_Modules -- "invokes" --> JSON_Unmarshalling_Utility + Service_Modules -- "interacts with" --> Event_Streaming_Utility + Service_Modules -- "utilizes" --> Hook_Context_Management + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.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) + +## Details + +These components are chosen based on their fundamental architectural importance in a Client-side SDK. The `Service Modules` are the primary interface for users, encapsulating domain logic. The `Security Utility` is essential for authentication, a core cross-cutting concern. `JSON Unmarshalling Utility` and `Event Streaming Utility` are vital for handling diverse API response formats. Finally, `Hook Context Management` provides the necessary extensibility, aligning with the "Extensibility" principle mentioned in the project context. This set of components provides a clear, modular, and functional breakdown of the SDK's core responsibilities. + +### Service Modules [[Expand]](./Service_Modules.md) +These modules encapsulate the core API domain logic for specific functionalities like Chat, Completions, Dataset management, and Image processing. They provide high-level, domain-specific methods that abstract the underlying API interactions, supporting both asynchronous and synchronous operations. This component is central to the SDK's usability, offering a clear interface for developers to interact with different parts of the Friendli API. + + +**Related Classes/Methods**: + +- `friendli_core.chat.SyncChat` (18:372) +- `friendli_core.chat.AsyncChat` (375:729) +- `friendli_core.completions.SyncCompletions` (18:194) +- `friendli_core.completions.AsyncCompletions` (197:373) +- `friendli_core.dataset.SyncDataset` (19:1528) +- `friendli_core.dataset.AsyncDataset` (1531:3040) +- `friendli_core.image.SyncImage` (18:118) +- `friendli_core.image.AsyncImage` (121:221) + + +### Security Utility +Responsible for securely retrieving and managing API credentials, typically from environment variables or other configuration sources. This component ensures that API requests are properly authenticated. + + +**Related Classes/Methods**: + +- `friendli_core.utils.security.get_security_from_env` (57:69) + + +### JSON Unmarshalling Utility +Handles the deserialization of JSON responses received from the Friendli API into structured Python objects. This component is crucial for converting raw API data into usable formats within the SDK. + + +**Related Classes/Methods**: + +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) + + +### Event Streaming Utility +Provides mechanisms for processing and managing streaming responses from the API, particularly for operations that return continuous data streams (e.g., chat completions). It abstracts the complexities of handling server-sent events or similar streaming protocols. + + +**Related Classes/Methods**: + +- `friendli_core.utils.eventstreaming.EventStream` (19:42) +- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) + + +### Hook Context Management +Manages an extensibility mechanism that allows developers to inject custom logic (hooks) at various points during the API interaction lifecycle. This component supports the SDK's extensibility, enabling custom pre-processing, post-processing, or error handling. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.HookContext` (11:30) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json new file mode 100644 index 0000000..b4e6597 --- /dev/null +++ b/.codeboarding/analysis.json @@ -0,0 +1,139 @@ +{ + "description": "One paragraph explaining the functionality which is represented by this graph. What the main flow is and what is its purpose.", + "components": [ + { + "name": "Friendli Client (Public API)", + "description": "The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.sdk", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/sdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "SDK Core", + "description": "The central orchestrator managing fundamental logic for API communication, request/response processing, and integrating foundational SDK abstractions and extensibility points.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.basesdk", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Service Modules", + "description": "Encapsulate specific API domains (e.g., chat, completions, datasets), providing high-level, domain-specific methods that simplify interactions with particular parts of the Friendli API.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.chat", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.completions", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.dataset", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.image", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Data Models & Error Handling", + "description": "Defines standardized data structures for API requests and responses, along with a comprehensive set of error types, ensuring consistent data representation and robust error reporting.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.models", + "reference_file": "N/A", + "reference_start_line": 0, + "reference_end_line": 0 + } + ], + "can_expand": true + }, + { + "name": "Platform Abstractions", + "description": "Provides base structures and interfaces tailored for different operational modes or deployment types within the Friendli platform, enabling the SDK to adapt its behavior to the target environment.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.dedicated", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core.serverless", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "can_expand": true + }, + { + "name": "Hooks & Extensibility", + "description": "Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks", + "reference_file": "N/A", + "reference_start_line": 0, + "reference_end_line": 0 + } + ], + "can_expand": false + } + ], + "components_relations": [ + { + "relation": "delegates requests to", + "src_name": "Friendli Client (Public API)", + "dst_name": "SDK Core" + }, + { + "relation": "utilizes", + "src_name": "SDK Core", + "dst_name": "Data Models & Error Handling" + }, + { + "relation": "adapts behavior based on", + "src_name": "SDK Core", + "dst_name": "Platform Abstractions" + }, + { + "relation": "integrates and consumes", + "src_name": "SDK Core", + "dst_name": "Hooks & Extensibility" + }, + { + "relation": "utilize", + "src_name": "Service Modules", + "dst_name": "SDK Core" + }, + { + "relation": "rely on", + "src_name": "Service Modules", + "dst_name": "Data Models & Error Handling" + } + ] +} diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json new file mode 100644 index 0000000..b83c854 --- /dev/null +++ b/.codeboarding/codeboarding_version.json @@ -0,0 +1,4 @@ +{ + "commit_hash": "27fb44c7574210fa86d30f07e3333dd9ca466d15", + "code_boarding_version": "0.1.0" +} diff --git a/.codeboarding/on_boarding.md b/.codeboarding/on_boarding.md new file mode 100644 index 0000000..41861a7 --- /dev/null +++ b/.codeboarding/on_boarding.md @@ -0,0 +1,88 @@ +```mermaid +graph LR + Friendli_Client_Public_API_["Friendli Client (Public API)"] + SDK_Core["SDK Core"] + Service_Modules["Service Modules"] + Data_Models_Error_Handling["Data Models & Error Handling"] + Platform_Abstractions["Platform Abstractions"] + Hooks_Extensibility["Hooks & Extensibility"] + Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core + SDK_Core -- "utilizes" --> Data_Models_Error_Handling + SDK_Core -- "adapts behavior based on" --> Platform_Abstractions + SDK_Core -- "integrates and consumes" --> Hooks_Extensibility + Service_Modules -- "utilize" --> SDK_Core + Service_Modules -- "rely on" --> Data_Models_Error_Handling + click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) + +## Details + +One paragraph explaining the functionality which is represented by this graph. What the main flow is and what is its purpose. + +### Friendli Client (Public API) [[Expand]](./Friendli_Client_Public_API_.md) +The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations. + + +**Related Classes/Methods**: + +- `friendli_core.sdk` + + +### SDK Core [[Expand]](./SDK_Core.md) +The central orchestrator managing fundamental logic for API communication, request/response processing, and integrating foundational SDK abstractions and extensibility points. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate specific API domains (e.g., chat, completions, datasets), providing high-level, domain-specific methods that simplify interactions with particular parts of the Friendli API. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.dataset` +- `friendli_core.image` + + +### Data Models & Error Handling [[Expand]](./Data_Models_Error_Handling.md) +Defines standardized data structures for API requests and responses, along with a comprehensive set of error types, ensuring consistent data representation and robust error reporting. + + +**Related Classes/Methods**: + +- `friendli_core.models` + + +### Platform Abstractions [[Expand]](./Platform_Abstractions.md) +Provides base structures and interfaces tailored for different operational modes or deployment types within the Friendli platform, enabling the SDK to adapt its behavior to the target environment. + + +**Related Classes/Methods**: + +- `friendli_core.dedicated` +- `friendli_core.serverless` + + +### Hooks & Extensibility +Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. + + +**Related Classes/Methods**: + +- `friendli_core._hooks` + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md new file mode 100644 index 0000000..6132c01 --- /dev/null +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -0,0 +1,78 @@ +```mermaid +graph LR + Core_Client["Core Client"] + Service_Modules["Service Modules"] + Data_Models_Error_Handling["Data Models & Error Handling"] + Utility_Functions["Utility Functions"] + Examples_and_Documentation["Examples and Documentation"] + Core_Client -- "uses" --> Service_Modules + Core_Client -- "uses" --> Data_Models_Error_Handling + Core_Client -- "uses" --> Utility_Functions + Service_Modules -- "utilizes" --> Data_Models_Error_Handling + Service_Modules -- "uses" --> Utility_Functions + Examples_and_Documentation -- "showcases usage of" --> Core_Client + Examples_and_Documentation -- "showcases usage of" --> Service_Modules + Examples_and_Documentation -- "relies on" --> Data_Models_Error_Handling + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) + +## Details + +This analysis outlines the final component structure of the `friendli_core` SDK, detailing its five key components: Core Client, Service Modules, Data Models & Error Handling, Utility Functions, and Examples and Documentation. It describes each component's role, associated source files, and interactions within the SDK, providing a comprehensive overview of the system's architecture and interdependencies. + +### Core Client +The central entry point for the SDK, responsible for managing authentication, session handling, and dispatching requests to the appropriate service modules. It provides the primary interface for users to interact with the Friendli AI platform. + + +**Related Classes/Methods**: + +- `friendli_core.client` (1:1) + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate specific API functionalities (e.g., chat, completions, image generation, audio processing). Each module provides high-level methods for its domain, abstracting the underlying RESTful API calls and handling domain-specific logic. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.image` +- `friendli_core.audio` + + +### Data Models & Error Handling [[Expand]](./Data_Models_Error_Handling.md) +Defines standardized data structures for all API requests and responses, ensuring consistent data representation across the SDK. This component also provides a comprehensive set of error types, facilitating robust and standardized error reporting from the Friendli AI platform. + + +**Related Classes/Methods**: + +- `friendli_core.models` (1:1) +- `friendli_core.errors` (1:1) + + +### Utility Functions +Provides common helper functions for SDK-wide tasks such as JSON serialization/deserialization, parameter validation, configuration loading, and other reusable logic that supports the core functionalities. + + +**Related Classes/Methods**: + +- `friendli_core.utils` (1:1) + + +### Examples and Documentation +Comprises practical code examples demonstrating how to effectively use the SDK's functionalities and comprehensive documentation (API references, guides) to assist developers in integrating and utilizing the Friendli AI platform. + + +**Related Classes/Methods**: + +- `examples` (1:1) +- `docs` (1:1) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/Friendli_Client_Public_API_.md b/docs/architecture/Friendli_Client_Public_API_.md new file mode 100644 index 0000000..d0fd9c6 --- /dev/null +++ b/docs/architecture/Friendli_Client_Public_API_.md @@ -0,0 +1,98 @@ +```mermaid +graph LR + Core_Client_Public_API_["Core Client (Public API)"] + Service_Modules["Service Modules"] + Data_Models["Data Models"] + HTTP_Client_Transport_Layer["HTTP Client/Transport Layer"] + Error_Handling["Error Handling"] + Configuration_Management["Configuration Management"] + Utility_Functions["Utility Functions"] + Core_Client_Public_API_ -- "uses" --> Service_Modules + Core_Client_Public_API_ -- "uses" --> Configuration_Management + Core_Client_Public_API_ -- "uses" --> Data_Models + Core_Client_Public_API_ -- "uses" --> Utility_Functions + Service_Modules -- "uses" --> HTTP_Client_Transport_Layer + Service_Modules -- "uses" --> Data_Models + Service_Modules -- "uses" --> Error_Handling + Service_Modules -- "uses" --> Utility_Functions + HTTP_Client_Transport_Layer -- "uses" --> Configuration_Management + HTTP_Client_Transport_Layer -- "uses" --> Error_Handling + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) + +## Details + +Final Component Overview for the `Friendli Client (Public API)` subsystem, structured according to Client-side SDK patterns. + +### Core Client (Public API) +The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations. It acts as the orchestrator, delegating requests to specific service modules. + + +**Related Classes/Methods**: + +- `friendli_core.sdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate the logic for interacting with specific API endpoints (e.g., chat, completions, images, audio). Each module handles the construction of requests, serialization of data models, and deserialization of responses for its domain. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.images` (1:1) +- `friendli_core.audio` + + +### Data Models +Define the structure of data exchanged with the Friendli AI platform, including request bodies, response objects, and various parameters. Ensures type safety and consistency across all API interactions within the SDK. + + +**Related Classes/Methods**: + +- `friendli_core.models` (1:1) + + +### HTTP Client/Transport Layer +Handles the low-level HTTP communication with the Friendli AI platform. This includes managing connections, sending requests, receiving responses, and abstracting away network-level concerns like retries and timeouts. + + +**Related Classes/Methods**: + +- `friendli_core.http_client` (1:1) + + +### Error Handling [[Expand]](./Error_Handling.md) +Manages and standardizes error responses from both the API and the network layer. It provides custom exception classes and mechanisms for users to gracefully handle API-related issues and network errors, ensuring a consistent error reporting experience. + + +**Related Classes/Methods**: + +- `friendli_core.errors` (1:1) + + +### Configuration Management +Centralizes and manages SDK-wide configuration settings, such as API keys, base URLs, default timeouts, and retry policies. It provides a consistent and accessible way to configure the SDK's behavior. + + +**Related Classes/Methods**: + +- `friendli_core.config` (1:1) + + +### Utility Functions +Provides common helper functions and reusable functionalities that support various parts of the SDK, such as authentication token management, data validation, or specific data transformations that are not tied to a particular API domain. + + +**Related Classes/Methods**: + +- `friendli_core.utils` (1:1) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/Platform_Abstractions.md b/docs/architecture/Platform_Abstractions.md new file mode 100644 index 0000000..0dc9c08 --- /dev/null +++ b/docs/architecture/Platform_Abstractions.md @@ -0,0 +1,50 @@ +```mermaid +graph LR + Platform_Abstractions["Platform Abstractions"] + Dedicated_Client["Dedicated Client"] + Serverless_Client["Serverless Client"] + Dedicated_Client -- "implements" --> Platform_Abstractions + Serverless_Client -- "implements" --> Platform_Abstractions + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) + +## Details + +Abstract Components Overview + +### Platform Abstractions [[Expand]](./Platform_Abstractions.md) +Defines the foundational base structures and interfaces that enable the SDK to adapt its behavior to various operational modes (e.g., dedicated, serverless) of the Friendli platform. It provides the abstract contracts for interacting with different deployment types. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk:BaseSDK` (19:106) + + +### Dedicated Client +A concrete implementation of the `Platform Abstractions` tailored specifically for interacting with the Friendli platform in a "dedicated" operational mode. It provides the specific logic and configurations required for this environment. + + +**Related Classes/Methods**: + +- `friendli_core.dedicated:BaseDedicated` (24:32) +- `friendli_core.dedicated:SyncDedicated` (35:49) +- `friendli_core.dedicated:AsyncDedicated` (52:66) + + +### Serverless Client +A concrete implementation of the `Platform Abstractions` designed for interacting with the Friendli platform in a "serverless" operational mode. It encapsulates the specific logic and configurations for this environment. + + +**Related Classes/Methods**: + +- `friendli_core.serverless:BaseServerless` (24:32) +- `friendli_core.serverless:SyncServerless` (35:49) +- `friendli_core.serverless:AsyncServerless` (52:68) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/SDK_Core.md b/docs/architecture/SDK_Core.md new file mode 100644 index 0000000..0aa48b1 --- /dev/null +++ b/docs/architecture/SDK_Core.md @@ -0,0 +1,115 @@ +```mermaid +graph LR + SDK_Core["SDK Core"] + Service_Modules["Service Modules"] + Data_Models["Data Models"] + Error_Handling["Error Handling"] + SDK_Configuration["SDK Configuration"] + Utility_Functions["Utility Functions"] + Asynchronous_Synchronous_Adapters["Asynchronous/Synchronous Adapters"] + Extensibility_Hooks_["Extensibility (Hooks)"] + SDK_Core -- "provides base classes to" --> Service_Modules + Service_Modules -- "utilizes" --> SDK_Core + SDK_Core -- "serializes/deserializes" --> Data_Models + Data_Models -- "defines format for" --> SDK_Core + SDK_Core -- "raises exceptions from" --> Error_Handling + Error_Handling -- "defines exceptions for" --> SDK_Core + SDK_Core -- "consumes settings from" --> SDK_Configuration + SDK_Configuration -- "provides parameters to" --> SDK_Core + SDK_Core -- "defines interface for" --> Asynchronous_Synchronous_Adapters + Asynchronous_Synchronous_Adapters -- "provides execution paths for" --> SDK_Core + SDK_Core -- "invokes" --> Extensibility_Hooks_ + Extensibility_Hooks_ -- "modifies behavior of" --> SDK_Core + Service_Modules -- "constructs requests with" --> Data_Models + Service_Modules -- "returns responses as" --> Data_Models + Service_Modules -- "handles exceptions from" --> Error_Handling + Error_Handling -- "defines error types for" --> Service_Modules + Utility_Functions -- "provides helpers to" --> SDK_Core + Utility_Functions -- "provides helpers to" --> Service_Modules + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) + +## Details + +This section synthesizes the architectural components of the Friendli AI Python SDK, focusing on the `SDK Core` and its interactions within a client-side SDK pattern. + +### SDK Core [[Expand]](./SDK_Core.md) +The foundational layer and central orchestrator of the SDK. It encapsulates the fundamental logic for API communication, request/response processing, and integrates core SDK abstractions. It provides the base classes (`BaseSDK`, `AsyncSDK`, `SyncSDK`) from which other service modules inherit, ensuring consistent interaction patterns and extensibility. It also manages global settings and extensibility points. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +These modules encapsulate specific API functionalities (e.g., Chat, Completions, Image, Dataset). They extend the `SDK Core`'s base classes to provide high-level, domain-specific methods for interacting with different parts of the Friendli AI platform. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` + + +### Data Models +Defines the structured data objects (e.g., request bodies, response objects) used for communication with the Friendli AI platform. These models ensure type safety, consistency, and ease of use when exchanging data with the API. + + +**Related Classes/Methods**: + +- `friendli_core.models` + + +### Error Handling [[Expand]](./Error_Handling.md) +Manages and standardizes error responses originating from the API or internal SDK operations. It provides custom exceptions and robust error handling mechanisms, allowing developers to gracefully manage and respond to issues. + + +**Related Classes/Methods**: + +- `friendli_core.errors` + + +### SDK Configuration +Manages global settings and parameters for the SDK, such as API keys, base URLs, timeouts, and other configurable options. It provides a centralized mechanism for developers to customize the SDK's behavior. + + +**Related Classes/Methods**: + +- `friendli_core.config` + + +### Utility Functions +Provides a collection of helper functions for common tasks that support the SDK's overall functionality. This includes operations like authentication, data serialization/deserialization, and other general-purpose utilities. + + +**Related Classes/Methods**: + +- `friendli_core.utils` + + +### Asynchronous/Synchronous Adapters +Provides distinct interfaces and implementations for both asynchronous (non-blocking) and synchronous (blocking) API calls. This allows developers to choose the appropriate execution model based on their application's architecture and performance requirements. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Extensibility (Hooks) +Offers mechanisms for extending SDK behavior through hooks or context objects (e.g., `HookContext`). This allows developers to inject custom logic at various points in the request/response lifecycle without altering the core SDK code. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/Service_Modules.md b/docs/architecture/Service_Modules.md new file mode 100644 index 0000000..3a387b3 --- /dev/null +++ b/docs/architecture/Service_Modules.md @@ -0,0 +1,76 @@ +```mermaid +graph LR + Service_Modules["Service Modules"] + Security_Utility["Security Utility"] + JSON_Unmarshalling_Utility["JSON Unmarshalling Utility"] + Event_Streaming_Utility["Event Streaming Utility"] + Hook_Context_Management["Hook Context Management"] + Service_Modules -- "calls" --> Security_Utility + Service_Modules -- "invokes" --> JSON_Unmarshalling_Utility + Service_Modules -- "interacts with" --> Event_Streaming_Utility + Service_Modules -- "utilizes" --> Hook_Context_Management + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.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) + +## Details + +These components are chosen based on their fundamental architectural importance in a Client-side SDK. The `Service Modules` are the primary interface for users, encapsulating domain logic. The `Security Utility` is essential for authentication, a core cross-cutting concern. `JSON Unmarshalling Utility` and `Event Streaming Utility` are vital for handling diverse API response formats. Finally, `Hook Context Management` provides the necessary extensibility, aligning with the "Extensibility" principle mentioned in the project context. This set of components provides a clear, modular, and functional breakdown of the SDK's core responsibilities. + +### Service Modules [[Expand]](./Service_Modules.md) +These modules encapsulate the core API domain logic for specific functionalities like Chat, Completions, Dataset management, and Image processing. They provide high-level, domain-specific methods that abstract the underlying API interactions, supporting both asynchronous and synchronous operations. This component is central to the SDK's usability, offering a clear interface for developers to interact with different parts of the Friendli API. + + +**Related Classes/Methods**: + +- `friendli_core.chat.SyncChat` (18:372) +- `friendli_core.chat.AsyncChat` (375:729) +- `friendli_core.completions.SyncCompletions` (18:194) +- `friendli_core.completions.AsyncCompletions` (197:373) +- `friendli_core.dataset.SyncDataset` (19:1528) +- `friendli_core.dataset.AsyncDataset` (1531:3040) +- `friendli_core.image.SyncImage` (18:118) +- `friendli_core.image.AsyncImage` (121:221) + + +### Security Utility +Responsible for securely retrieving and managing API credentials, typically from environment variables or other configuration sources. This component ensures that API requests are properly authenticated. + + +**Related Classes/Methods**: + +- `friendli_core.utils.security.get_security_from_env` (57:69) + + +### JSON Unmarshalling Utility +Handles the deserialization of JSON responses received from the Friendli API into structured Python objects. This component is crucial for converting raw API data into usable formats within the SDK. + + +**Related Classes/Methods**: + +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) + + +### Event Streaming Utility +Provides mechanisms for processing and managing streaming responses from the API, particularly for operations that return continuous data streams (e.g., chat completions). It abstracts the complexities of handling server-sent events or similar streaming protocols. + + +**Related Classes/Methods**: + +- `friendli_core.utils.eventstreaming.EventStream` (19:42) +- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) + + +### Hook Context Management +Manages an extensibility mechanism that allows developers to inject custom logic (hooks) at various points during the API interaction lifecycle. This component supports the SDK's extensibility, enabling custom pre-processing, post-processing, or error handling. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.HookContext` (11:30) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md new file mode 100644 index 0000000..decee94 --- /dev/null +++ b/docs/architecture/on_boarding.md @@ -0,0 +1,91 @@ +```mermaid +graph LR + Friendli_Client_Public_API_["Friendli Client (Public API)"] + SDK_Core["SDK Core"] + Service_Modules["Service Modules"] + Data_Models_Error_Handling["Data Models & Error Handling"] + Platform_Abstractions["Platform Abstractions"] + Hooks_Extensibility["Hooks & Extensibility"] + Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core + SDK_Core -- "utilizes" --> Data_Models_Error_Handling + SDK_Core -- "adapts behavior based on" --> Platform_Abstractions + SDK_Core -- "integrates and consumes" --> Hooks_Extensibility + Service_Modules -- "utilize" --> SDK_Core + Service_Modules -- "rely on" --> Data_Models_Error_Handling + click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) + +## Details + +One paragraph explaining the functionality which is represented by this graph. What the main flow is and what is its purpose. + +### Friendli Client (Public API) [[Expand]](./Friendli_Client_Public_API_.md) +The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations. + + +**Related Classes/Methods**: + +- `friendli_core.sdk` + + +### SDK Core [[Expand]](./SDK_Core.md) +The central orchestrator managing fundamental logic for API communication, request/response processing, and integrating foundational SDK abstractions and extensibility points. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate specific API domains (e.g., chat, completions, datasets), providing high-level, domain-specific methods that simplify interactions with particular parts of the Friendli API. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.dataset` +- `friendli_core.image` + + +### Data Models & Error Handling [[Expand]](./Data_Models_Error_Handling.md) +Defines standardized data structures for API requests and responses, along with a comprehensive set of error types, ensuring consistent data representation and robust error reporting. + + +**Related Classes/Methods**: + +- `friendli_core.models` + + +### Platform Abstractions [[Expand]](./Platform_Abstractions.md) +Provides base structures and interfaces tailored for different operational modes or deployment types within the Friendli platform, enabling the SDK to adapt its behavior to the target environment. + + +**Related Classes/Methods**: + +- `friendli_core.dedicated` +- `friendli_core.serverless` + + +### Hooks & Extensibility +Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. + + +**Related Classes/Methods**: + +- `friendli_core._hooks` + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) +- [on_boarding.md](./on_boarding.md) + +_Last updated: 2025-07-26 05:04:17 UTC_ From 6ecf41c35cb588078b552dadff52500a57ae6fe1 Mon Sep 17 00:00:00 2001 From: ivanmilevtues Date: Fri, 25 Jul 2025 23:00:51 -0700 Subject: [PATCH 04/29] Readme text enhance. --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index b1225a2..65b4410 100644 --- a/README.md +++ b/README.md @@ -19,8 +19,7 @@ When using Friendli Python SDK, you need to provide a Friendli Token for authent ## Architecture & Development Onboarding -For developers looking to understand the codebase architecture and get started with contributing to the Friendli Python SDK, please refer to our comprehensive [Architecture & Onboarding Guide](./docs/architecture/on_boarding.md). This documentation is automatically generated and maintained to provide up-to-date insights into the codebase structure, patterns, and development workflows. - +For developers looking to understand the codebase architecture and get started with contributing to the Friendli Python SDK, please refer to our [Architecture Documentation](./docs/architecture/on_boarding.md). From b40eabdc552d1974ad77c8ff8bd045d3985fb7fc Mon Sep 17 00:00:00 2001 From: ivanmilevtues Date: Fri, 25 Jul 2025 23:03:45 -0700 Subject: [PATCH 05/29] Fixed linking to root repo. --- .codeboarding/Data_Models_Error_Handling.md | 4 +-- .codeboarding/Friendli_Client_Public_API_.md | 4 +-- .codeboarding/Platform_Abstractions.md | 16 +++++------ .codeboarding/SDK_Core.md | 6 ++-- .codeboarding/Service_Modules.md | 28 +++++++++---------- .codeboarding/on_boarding.md | 10 +++---- .../Data_Models_Error_Handling.md | 4 +-- .../Friendli_Client_Public_API_.md | 4 +-- docs/architecture/Platform_Abstractions.md | 16 +++++------ docs/architecture/SDK_Core.md | 6 ++-- docs/architecture/Service_Modules.md | 28 +++++++++---------- docs/architecture/on_boarding.md | 10 +++---- 12 files changed, 68 insertions(+), 68 deletions(-) diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md index 6132c01..f88bf49 100644 --- a/.codeboarding/Data_Models_Error_Handling.md +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -13,8 +13,8 @@ graph LR Examples_and_Documentation -- "showcases usage of" --> Core_Client Examples_and_Documentation -- "showcases usage of" --> Service_Modules Examples_and_Documentation -- "relies on" --> Data_Models_Error_Handling - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) diff --git a/.codeboarding/Friendli_Client_Public_API_.md b/.codeboarding/Friendli_Client_Public_API_.md index d0fd9c6..90d2dfb 100644 --- a/.codeboarding/Friendli_Client_Public_API_.md +++ b/.codeboarding/Friendli_Client_Public_API_.md @@ -17,8 +17,8 @@ graph LR Service_Modules -- "uses" --> Utility_Functions HTTP_Client_Transport_Layer -- "uses" --> Configuration_Management HTTP_Client_Transport_Layer -- "uses" --> Error_Handling - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/.codeboarding/Platform_Abstractions.md b/.codeboarding/Platform_Abstractions.md index 0dc9c08..042b3b3 100644 --- a/.codeboarding/Platform_Abstractions.md +++ b/.codeboarding/Platform_Abstractions.md @@ -5,7 +5,7 @@ graph LR Serverless_Client["Serverless Client"] Dedicated_Client -- "implements" --> Platform_Abstractions Serverless_Client -- "implements" --> Platform_Abstractions - click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) @@ -20,7 +20,7 @@ Defines the foundational base structures and interfaces that enable the SDK to a **Related Classes/Methods**: -- `friendli_core.basesdk:BaseSDK` (19:106) +- `friendli_core.basesdk:BaseSDK` (19:106) ### Dedicated Client @@ -29,9 +29,9 @@ A concrete implementation of the `Platform Abstractions` tailored specifically f **Related Classes/Methods**: -- `friendli_core.dedicated:BaseDedicated` (24:32) -- `friendli_core.dedicated:SyncDedicated` (35:49) -- `friendli_core.dedicated:AsyncDedicated` (52:66) +- `friendli_core.dedicated:BaseDedicated` (24:32) +- `friendli_core.dedicated:SyncDedicated` (35:49) +- `friendli_core.dedicated:AsyncDedicated` (52:66) ### Serverless Client @@ -40,9 +40,9 @@ A concrete implementation of the `Platform Abstractions` designed for interactin **Related Classes/Methods**: -- `friendli_core.serverless:BaseServerless` (24:32) -- `friendli_core.serverless:SyncServerless` (35:49) -- `friendli_core.serverless:AsyncServerless` (52:68) +- `friendli_core.serverless:BaseServerless` (24:32) +- `friendli_core.serverless:SyncServerless` (35:49) +- `friendli_core.serverless:AsyncServerless` (52:68) diff --git a/.codeboarding/SDK_Core.md b/.codeboarding/SDK_Core.md index 0aa48b1..7bd9809 100644 --- a/.codeboarding/SDK_Core.md +++ b/.codeboarding/SDK_Core.md @@ -26,9 +26,9 @@ graph LR Error_Handling -- "defines error types for" --> Service_Modules Utility_Functions -- "provides helpers to" --> SDK_Core Utility_Functions -- "provides helpers to" --> Service_Modules - click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/.codeboarding/Service_Modules.md b/.codeboarding/Service_Modules.md index 3a387b3..5184731 100644 --- a/.codeboarding/Service_Modules.md +++ b/.codeboarding/Service_Modules.md @@ -9,7 +9,7 @@ graph LR Service_Modules -- "invokes" --> JSON_Unmarshalling_Utility Service_Modules -- "interacts with" --> Event_Streaming_Utility Service_Modules -- "utilizes" --> Hook_Context_Management - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.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) @@ -24,14 +24,14 @@ These modules encapsulate the core API domain logic for specific functionalities **Related Classes/Methods**: -- `friendli_core.chat.SyncChat` (18:372) -- `friendli_core.chat.AsyncChat` (375:729) -- `friendli_core.completions.SyncCompletions` (18:194) -- `friendli_core.completions.AsyncCompletions` (197:373) -- `friendli_core.dataset.SyncDataset` (19:1528) -- `friendli_core.dataset.AsyncDataset` (1531:3040) -- `friendli_core.image.SyncImage` (18:118) -- `friendli_core.image.AsyncImage` (121:221) +- `friendli_core.chat.SyncChat` (18:372) +- `friendli_core.chat.AsyncChat` (375:729) +- `friendli_core.completions.SyncCompletions` (18:194) +- `friendli_core.completions.AsyncCompletions` (197:373) +- `friendli_core.dataset.SyncDataset` (19:1528) +- `friendli_core.dataset.AsyncDataset` (1531:3040) +- `friendli_core.image.SyncImage` (18:118) +- `friendli_core.image.AsyncImage` (121:221) ### Security Utility @@ -40,7 +40,7 @@ Responsible for securely retrieving and managing API credentials, typically from **Related Classes/Methods**: -- `friendli_core.utils.security.get_security_from_env` (57:69) +- `friendli_core.utils.security.get_security_from_env` (57:69) ### JSON Unmarshalling Utility @@ -49,7 +49,7 @@ Handles the deserialization of JSON responses received from the Friendli API int **Related Classes/Methods**: -- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) ### Event Streaming Utility @@ -58,8 +58,8 @@ Provides mechanisms for processing and managing streaming responses from the API **Related Classes/Methods**: -- `friendli_core.utils.eventstreaming.EventStream` (19:42) -- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) +- `friendli_core.utils.eventstreaming.EventStream` (19:42) +- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) ### Hook Context Management @@ -68,7 +68,7 @@ Manages an extensibility mechanism that allows developers to inject custom logic **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.HookContext` (11:30) diff --git a/.codeboarding/on_boarding.md b/.codeboarding/on_boarding.md index 41861a7..b39e2f0 100644 --- a/.codeboarding/on_boarding.md +++ b/.codeboarding/on_boarding.md @@ -12,11 +12,11 @@ graph LR SDK_Core -- "integrates and consumes" --> Hooks_Extensibility Service_Modules -- "utilize" --> SDK_Core Service_Modules -- "rely on" --> Data_Models_Error_Handling - click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" - click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" - click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Friendli_Client_Public_API_ href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md index 6132c01..f88bf49 100644 --- a/docs/architecture/Data_Models_Error_Handling.md +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -13,8 +13,8 @@ graph LR Examples_and_Documentation -- "showcases usage of" --> Core_Client Examples_and_Documentation -- "showcases usage of" --> Service_Modules Examples_and_Documentation -- "relies on" --> Data_Models_Error_Handling - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) diff --git a/docs/architecture/Friendli_Client_Public_API_.md b/docs/architecture/Friendli_Client_Public_API_.md index d0fd9c6..90d2dfb 100644 --- a/docs/architecture/Friendli_Client_Public_API_.md +++ b/docs/architecture/Friendli_Client_Public_API_.md @@ -17,8 +17,8 @@ graph LR Service_Modules -- "uses" --> Utility_Functions HTTP_Client_Transport_Layer -- "uses" --> Configuration_Management HTTP_Client_Transport_Layer -- "uses" --> Error_Handling - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/docs/architecture/Platform_Abstractions.md b/docs/architecture/Platform_Abstractions.md index 0dc9c08..042b3b3 100644 --- a/docs/architecture/Platform_Abstractions.md +++ b/docs/architecture/Platform_Abstractions.md @@ -5,7 +5,7 @@ graph LR Serverless_Client["Serverless Client"] Dedicated_Client -- "implements" --> Platform_Abstractions Serverless_Client -- "implements" --> Platform_Abstractions - click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) @@ -20,7 +20,7 @@ Defines the foundational base structures and interfaces that enable the SDK to a **Related Classes/Methods**: -- `friendli_core.basesdk:BaseSDK` (19:106) +- `friendli_core.basesdk:BaseSDK` (19:106) ### Dedicated Client @@ -29,9 +29,9 @@ A concrete implementation of the `Platform Abstractions` tailored specifically f **Related Classes/Methods**: -- `friendli_core.dedicated:BaseDedicated` (24:32) -- `friendli_core.dedicated:SyncDedicated` (35:49) -- `friendli_core.dedicated:AsyncDedicated` (52:66) +- `friendli_core.dedicated:BaseDedicated` (24:32) +- `friendli_core.dedicated:SyncDedicated` (35:49) +- `friendli_core.dedicated:AsyncDedicated` (52:66) ### Serverless Client @@ -40,9 +40,9 @@ A concrete implementation of the `Platform Abstractions` designed for interactin **Related Classes/Methods**: -- `friendli_core.serverless:BaseServerless` (24:32) -- `friendli_core.serverless:SyncServerless` (35:49) -- `friendli_core.serverless:AsyncServerless` (52:68) +- `friendli_core.serverless:BaseServerless` (24:32) +- `friendli_core.serverless:SyncServerless` (35:49) +- `friendli_core.serverless:AsyncServerless` (52:68) diff --git a/docs/architecture/SDK_Core.md b/docs/architecture/SDK_Core.md index 0aa48b1..7bd9809 100644 --- a/docs/architecture/SDK_Core.md +++ b/docs/architecture/SDK_Core.md @@ -26,9 +26,9 @@ graph LR Error_Handling -- "defines error types for" --> Service_Modules Utility_Functions -- "provides helpers to" --> SDK_Core Utility_Functions -- "provides helpers to" --> Service_Modules - click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/docs/architecture/Service_Modules.md b/docs/architecture/Service_Modules.md index 3a387b3..5184731 100644 --- a/docs/architecture/Service_Modules.md +++ b/docs/architecture/Service_Modules.md @@ -9,7 +9,7 @@ graph LR Service_Modules -- "invokes" --> JSON_Unmarshalling_Utility Service_Modules -- "interacts with" --> Event_Streaming_Utility Service_Modules -- "utilizes" --> Hook_Context_Management - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.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) @@ -24,14 +24,14 @@ These modules encapsulate the core API domain logic for specific functionalities **Related Classes/Methods**: -- `friendli_core.chat.SyncChat` (18:372) -- `friendli_core.chat.AsyncChat` (375:729) -- `friendli_core.completions.SyncCompletions` (18:194) -- `friendli_core.completions.AsyncCompletions` (197:373) -- `friendli_core.dataset.SyncDataset` (19:1528) -- `friendli_core.dataset.AsyncDataset` (1531:3040) -- `friendli_core.image.SyncImage` (18:118) -- `friendli_core.image.AsyncImage` (121:221) +- `friendli_core.chat.SyncChat` (18:372) +- `friendli_core.chat.AsyncChat` (375:729) +- `friendli_core.completions.SyncCompletions` (18:194) +- `friendli_core.completions.AsyncCompletions` (197:373) +- `friendli_core.dataset.SyncDataset` (19:1528) +- `friendli_core.dataset.AsyncDataset` (1531:3040) +- `friendli_core.image.SyncImage` (18:118) +- `friendli_core.image.AsyncImage` (121:221) ### Security Utility @@ -40,7 +40,7 @@ Responsible for securely retrieving and managing API credentials, typically from **Related Classes/Methods**: -- `friendli_core.utils.security.get_security_from_env` (57:69) +- `friendli_core.utils.security.get_security_from_env` (57:69) ### JSON Unmarshalling Utility @@ -49,7 +49,7 @@ Handles the deserialization of JSON responses received from the Friendli API int **Related Classes/Methods**: -- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) ### Event Streaming Utility @@ -58,8 +58,8 @@ Provides mechanisms for processing and managing streaming responses from the API **Related Classes/Methods**: -- `friendli_core.utils.eventstreaming.EventStream` (19:42) -- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) +- `friendli_core.utils.eventstreaming.EventStream` (19:42) +- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) ### Hook Context Management @@ -68,7 +68,7 @@ Manages an extensibility mechanism that allows developers to inject custom logic **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.HookContext` (11:30) diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index decee94..0fd781d 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -12,11 +12,11 @@ graph LR SDK_Core -- "integrates and consumes" --> Hooks_Extensibility Service_Modules -- "utilize" --> SDK_Core Service_Modules -- "rely on" --> Data_Models_Error_Handling - click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" - click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" - click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Friendli_Client_Public_API_ href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) From 46ff1e4ea0a7512e7d24a67e830ecc2a277795a5 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 26 Jul 2025 20:36:23 +0000 Subject: [PATCH 06/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Data_Models_Error_Handling.json | 15 ++-- .codeboarding/Data_Models_Error_Handling.md | 4 +- .../Friendli_Client_Public_API_.json | 21 ++--- .codeboarding/Friendli_Client_Public_API_.md | 4 +- .codeboarding/Hooks_Extensibility.json | 84 +++++++++++++++++++ .codeboarding/Hooks_Extensibility.md | 50 +++++++++++ .codeboarding/Platform_Abstractions.json | 9 +- .codeboarding/Platform_Abstractions.md | 16 ++-- .codeboarding/SDK_Core.json | 24 ++---- .codeboarding/SDK_Core.md | 6 +- .codeboarding/Service_Modules.json | 15 ++-- .codeboarding/Service_Modules.md | 28 +++---- .codeboarding/analysis.json | 2 +- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/on_boarding.md | 13 +-- .../Data_Models_Error_Handling.md | 4 +- .../Friendli_Client_Public_API_.md | 4 +- docs/architecture/Hooks_Extensibility.md | 50 +++++++++++ docs/architecture/Platform_Abstractions.md | 16 ++-- docs/architecture/SDK_Core.md | 6 +- docs/architecture/Service_Modules.md | 28 +++---- docs/architecture/on_boarding.md | 15 ++-- 22 files changed, 287 insertions(+), 129 deletions(-) create mode 100644 .codeboarding/Hooks_Extensibility.json create mode 100644 .codeboarding/Hooks_Extensibility.md create mode 100644 docs/architecture/Hooks_Extensibility.md diff --git a/.codeboarding/Data_Models_Error_Handling.json b/.codeboarding/Data_Models_Error_Handling.json index 209474e..1089c1d 100644 --- a/.codeboarding/Data_Models_Error_Handling.json +++ b/.codeboarding/Data_Models_Error_Handling.json @@ -11,8 +11,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": true + ] }, { "name": "Service Modules", @@ -42,8 +41,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] }, { "name": "Data Models & Error Handling", @@ -61,8 +59,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": true + ] }, { "name": "Utility Functions", @@ -74,8 +71,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": false + ] }, { "name": "Examples and Documentation", @@ -93,8 +89,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": false + ] } ], "components_relations": [ diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md index f88bf49..6132c01 100644 --- a/.codeboarding/Data_Models_Error_Handling.md +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -13,8 +13,8 @@ graph LR Examples_and_Documentation -- "showcases usage of" --> Core_Client Examples_and_Documentation -- "showcases usage of" --> Service_Modules Examples_and_Documentation -- "relies on" --> Data_Models_Error_Handling - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) diff --git a/.codeboarding/Friendli_Client_Public_API_.json b/.codeboarding/Friendli_Client_Public_API_.json index 6dc6402..cf2c3f9 100644 --- a/.codeboarding/Friendli_Client_Public_API_.json +++ b/.codeboarding/Friendli_Client_Public_API_.json @@ -11,8 +11,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] }, { "name": "Service Modules", @@ -42,8 +41,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] }, { "name": "Data Models", @@ -55,8 +53,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": false + ] }, { "name": "HTTP Client/Transport Layer", @@ -68,8 +65,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": true + ] }, { "name": "Error Handling", @@ -81,8 +77,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": true + ] }, { "name": "Configuration Management", @@ -94,8 +89,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": false + ] }, { "name": "Utility Functions", @@ -107,8 +101,7 @@ "reference_start_line": 1, "reference_end_line": 1 } - ], - "can_expand": true + ] } ], "components_relations": [ diff --git a/.codeboarding/Friendli_Client_Public_API_.md b/.codeboarding/Friendli_Client_Public_API_.md index 90d2dfb..d0fd9c6 100644 --- a/.codeboarding/Friendli_Client_Public_API_.md +++ b/.codeboarding/Friendli_Client_Public_API_.md @@ -17,8 +17,8 @@ graph LR Service_Modules -- "uses" --> Utility_Functions HTTP_Client_Transport_Layer -- "uses" --> Configuration_Management HTTP_Client_Transport_Layer -- "uses" --> Error_Handling - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json new file mode 100644 index 0000000..20e610f --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.json @@ -0,0 +1,84 @@ +{ + "description": "Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization.", + "components": [ + { + "name": "Hook Contexts (DTOs)", + "description": "A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass relevant data and state through different stages of the API request/response lifecycle. These contexts provide the necessary information for hooks to operate on.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.types.HookContext", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", + "reference_start_line": 11, + "reference_end_line": 30 + }, + { + "qualified_name": "friendli_core._hooks.types.BeforeRequestContext", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", + "reference_start_line": 33, + "reference_end_line": 41 + }, + { + "qualified_name": "friendli_core._hooks.types.AfterSuccessContext", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", + "reference_start_line": 44, + "reference_end_line": 52 + }, + { + "qualified_name": "friendli_core._hooks.types.AfterErrorContext", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", + "reference_start_line": 55, + "reference_end_line": 63 + } + ], + "can_expand": false + }, + { + "name": "Hook Interface", + "description": "Defines the abstract interface or base class that custom hooks must implement. It establishes the contract for various hook methods (e.g., `before_request`, `after_success`, `after_error`), ensuring a consistent extensibility point for SDK users.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.types.Hooks", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", + "reference_start_line": 99, + "reference_end_line": 114 + } + ], + "can_expand": false + }, + { + "name": "SDK Hooks Orchestrator", + "description": "The central manager responsible for registering, storing, and orchestrating the execution of various custom hooks at the appropriate stages of the SDK's request/response lifecycle. It acts as a facade for the entire hooks mechanism.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.sdkhooks.SDKHooks", + "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/sdkhooks.py", + "reference_start_line": 21, + "reference_end_line": 78 + } + ], + "can_expand": true + } + ], + "components_relations": [ + { + "relation": "provides data to", + "src_name": "Hook Contexts (DTOs)", + "dst_name": "Hook Interface" + }, + { + "relation": "interacts with", + "src_name": "SDK Hooks Orchestrator", + "dst_name": "Hook Contexts (DTOs)" + }, + { + "relation": "orchestrates", + "src_name": "SDK Hooks Orchestrator", + "dst_name": "Hook Interface" + }, + { + "relation": "receives", + "src_name": "Hook Interface", + "dst_name": "Hook Contexts (DTOs)" + } + ] +} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md new file mode 100644 index 0000000..1ee6e91 --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.md @@ -0,0 +1,50 @@ +```mermaid +graph LR + Hook_Contexts_DTOs_["Hook Contexts (DTOs)"] + Hook_Interface["Hook Interface"] + SDK_Hooks_Orchestrator["SDK Hooks Orchestrator"] + Hook_Contexts_DTOs_ -- "provides data to" --> Hook_Interface + SDK_Hooks_Orchestrator -- "interacts with" --> Hook_Contexts_DTOs_ + SDK_Hooks_Orchestrator -- "orchestrates" --> Hook_Interface + Hook_Interface -- "receives" --> Hook_Contexts_DTOs_ +``` + +[![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) + +## Details + +Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. + +### Hook Contexts (DTOs) +A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass relevant data and state through different stages of the API request/response lifecycle. These contexts provide the necessary information for hooks to operate on. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.BeforeRequestContext` (33:41) +- `friendli_core._hooks.types.AfterSuccessContext` (44:52) +- `friendli_core._hooks.types.AfterErrorContext` (55:63) + + +### Hook Interface +Defines the abstract interface or base class that custom hooks must implement. It establishes the contract for various hook methods (e.g., `before_request`, `after_success`, `after_error`), ensuring a consistent extensibility point for SDK users. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.Hooks` (99:114) + + +### SDK Hooks Orchestrator +The central manager responsible for registering, storing, and orchestrating the execution of various custom hooks at the appropriate stages of the SDK's request/response lifecycle. It acts as a facade for the entire hooks mechanism. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.sdkhooks.SDKHooks` (21:78) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/Platform_Abstractions.json b/.codeboarding/Platform_Abstractions.json index 7af4799..711230c 100644 --- a/.codeboarding/Platform_Abstractions.json +++ b/.codeboarding/Platform_Abstractions.json @@ -11,8 +11,7 @@ "reference_start_line": 19, "reference_end_line": 106 } - ], - "can_expand": true + ] }, { "name": "Dedicated Client", @@ -36,8 +35,7 @@ "reference_start_line": 52, "reference_end_line": 66 } - ], - "can_expand": true + ] }, { "name": "Serverless Client", @@ -61,8 +59,7 @@ "reference_start_line": 52, "reference_end_line": 68 } - ], - "can_expand": true + ] } ], "components_relations": [ diff --git a/.codeboarding/Platform_Abstractions.md b/.codeboarding/Platform_Abstractions.md index 042b3b3..0dc9c08 100644 --- a/.codeboarding/Platform_Abstractions.md +++ b/.codeboarding/Platform_Abstractions.md @@ -5,7 +5,7 @@ graph LR Serverless_Client["Serverless Client"] Dedicated_Client -- "implements" --> Platform_Abstractions Serverless_Client -- "implements" --> Platform_Abstractions - click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) @@ -20,7 +20,7 @@ Defines the foundational base structures and interfaces that enable the SDK to a **Related Classes/Methods**: -- `friendli_core.basesdk:BaseSDK` (19:106) +- `friendli_core.basesdk:BaseSDK` (19:106) ### Dedicated Client @@ -29,9 +29,9 @@ A concrete implementation of the `Platform Abstractions` tailored specifically f **Related Classes/Methods**: -- `friendli_core.dedicated:BaseDedicated` (24:32) -- `friendli_core.dedicated:SyncDedicated` (35:49) -- `friendli_core.dedicated:AsyncDedicated` (52:66) +- `friendli_core.dedicated:BaseDedicated` (24:32) +- `friendli_core.dedicated:SyncDedicated` (35:49) +- `friendli_core.dedicated:AsyncDedicated` (52:66) ### Serverless Client @@ -40,9 +40,9 @@ A concrete implementation of the `Platform Abstractions` designed for interactin **Related Classes/Methods**: -- `friendli_core.serverless:BaseServerless` (24:32) -- `friendli_core.serverless:SyncServerless` (35:49) -- `friendli_core.serverless:AsyncServerless` (52:68) +- `friendli_core.serverless:BaseServerless` (24:32) +- `friendli_core.serverless:SyncServerless` (35:49) +- `friendli_core.serverless:AsyncServerless` (52:68) diff --git a/.codeboarding/SDK_Core.json b/.codeboarding/SDK_Core.json index 5c06704..2b5d84e 100644 --- a/.codeboarding/SDK_Core.json +++ b/.codeboarding/SDK_Core.json @@ -11,8 +11,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] }, { "name": "Service Modules", @@ -30,8 +29,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] }, { "name": "Data Models", @@ -43,8 +41,7 @@ "reference_start_line": 0, "reference_end_line": 0 } - ], - "can_expand": true + ] }, { "name": "Error Handling", @@ -56,8 +53,7 @@ "reference_start_line": 0, "reference_end_line": 0 } - ], - "can_expand": false + ] }, { "name": "SDK Configuration", @@ -69,8 +65,7 @@ "reference_start_line": 0, "reference_end_line": 0 } - ], - "can_expand": true + ] }, { "name": "Utility Functions", @@ -82,8 +77,7 @@ "reference_start_line": 0, "reference_end_line": 0 } - ], - "can_expand": true + ] }, { "name": "Asynchronous/Synchronous Adapters", @@ -95,8 +89,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] }, { "name": "Extensibility (Hooks)", @@ -108,8 +101,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "can_expand": true + ] } ], "components_relations": [ diff --git a/.codeboarding/SDK_Core.md b/.codeboarding/SDK_Core.md index 7bd9809..0aa48b1 100644 --- a/.codeboarding/SDK_Core.md +++ b/.codeboarding/SDK_Core.md @@ -26,9 +26,9 @@ graph LR Error_Handling -- "defines error types for" --> Service_Modules Utility_Functions -- "provides helpers to" --> SDK_Core Utility_Functions -- "provides helpers to" --> Service_Modules - click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/.codeboarding/Service_Modules.json b/.codeboarding/Service_Modules.json index 349839b..0b09674 100644 --- a/.codeboarding/Service_Modules.json +++ b/.codeboarding/Service_Modules.json @@ -53,8 +53,7 @@ "reference_start_line": 121, "reference_end_line": 221 } - ], - "can_expand": true + ] }, { "name": "Security Utility", @@ -66,8 +65,7 @@ "reference_start_line": 57, "reference_end_line": 69 } - ], - "can_expand": false + ] }, { "name": "JSON Unmarshalling Utility", @@ -79,8 +77,7 @@ "reference_start_line": 11, "reference_end_line": 24 } - ], - "can_expand": false + ] }, { "name": "Event Streaming Utility", @@ -98,8 +95,7 @@ "reference_start_line": 45, "reference_end_line": 68 } - ], - "can_expand": false + ] }, { "name": "Hook Context Management", @@ -111,8 +107,7 @@ "reference_start_line": 11, "reference_end_line": 30 } - ], - "can_expand": true + ] } ], "components_relations": [ diff --git a/.codeboarding/Service_Modules.md b/.codeboarding/Service_Modules.md index 5184731..3a387b3 100644 --- a/.codeboarding/Service_Modules.md +++ b/.codeboarding/Service_Modules.md @@ -9,7 +9,7 @@ graph LR Service_Modules -- "invokes" --> JSON_Unmarshalling_Utility Service_Modules -- "interacts with" --> Event_Streaming_Utility Service_Modules -- "utilizes" --> Hook_Context_Management - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.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) @@ -24,14 +24,14 @@ These modules encapsulate the core API domain logic for specific functionalities **Related Classes/Methods**: -- `friendli_core.chat.SyncChat` (18:372) -- `friendli_core.chat.AsyncChat` (375:729) -- `friendli_core.completions.SyncCompletions` (18:194) -- `friendli_core.completions.AsyncCompletions` (197:373) -- `friendli_core.dataset.SyncDataset` (19:1528) -- `friendli_core.dataset.AsyncDataset` (1531:3040) -- `friendli_core.image.SyncImage` (18:118) -- `friendli_core.image.AsyncImage` (121:221) +- `friendli_core.chat.SyncChat` (18:372) +- `friendli_core.chat.AsyncChat` (375:729) +- `friendli_core.completions.SyncCompletions` (18:194) +- `friendli_core.completions.AsyncCompletions` (197:373) +- `friendli_core.dataset.SyncDataset` (19:1528) +- `friendli_core.dataset.AsyncDataset` (1531:3040) +- `friendli_core.image.SyncImage` (18:118) +- `friendli_core.image.AsyncImage` (121:221) ### Security Utility @@ -40,7 +40,7 @@ Responsible for securely retrieving and managing API credentials, typically from **Related Classes/Methods**: -- `friendli_core.utils.security.get_security_from_env` (57:69) +- `friendli_core.utils.security.get_security_from_env` (57:69) ### JSON Unmarshalling Utility @@ -49,7 +49,7 @@ Handles the deserialization of JSON responses received from the Friendli API int **Related Classes/Methods**: -- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) ### Event Streaming Utility @@ -58,8 +58,8 @@ Provides mechanisms for processing and managing streaming responses from the API **Related Classes/Methods**: -- `friendli_core.utils.eventstreaming.EventStream` (19:42) -- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) +- `friendli_core.utils.eventstreaming.EventStream` (19:42) +- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) ### Hook Context Management @@ -68,7 +68,7 @@ Manages an extensibility mechanism that allows developers to inject custom logic **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.HookContext` (11:30) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index b4e6597..f177c29 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -101,7 +101,7 @@ "reference_end_line": 0 } ], - "can_expand": false + "can_expand": true } ], "components_relations": [ diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index b83c854..b32a4a8 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "27fb44c7574210fa86d30f07e3333dd9ca466d15", + "commit_hash": "b40eabdc552d1974ad77c8ff8bd045d3985fb7fc", "code_boarding_version": "0.1.0" } diff --git a/.codeboarding/on_boarding.md b/.codeboarding/on_boarding.md index b39e2f0..7a6e359 100644 --- a/.codeboarding/on_boarding.md +++ b/.codeboarding/on_boarding.md @@ -12,11 +12,12 @@ graph LR SDK_Core -- "integrates and consumes" --> Hooks_Extensibility Service_Modules -- "utilize" --> SDK_Core Service_Modules -- "rely on" --> Data_Models_Error_Handling - click Friendli_Client_Public_API_ href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" - click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" - click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.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) @@ -74,7 +75,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md index f88bf49..6132c01 100644 --- a/docs/architecture/Data_Models_Error_Handling.md +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -13,8 +13,8 @@ graph LR Examples_and_Documentation -- "showcases usage of" --> Core_Client Examples_and_Documentation -- "showcases usage of" --> Service_Modules Examples_and_Documentation -- "relies on" --> Data_Models_Error_Handling - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) diff --git a/docs/architecture/Friendli_Client_Public_API_.md b/docs/architecture/Friendli_Client_Public_API_.md index 90d2dfb..d0fd9c6 100644 --- a/docs/architecture/Friendli_Client_Public_API_.md +++ b/docs/architecture/Friendli_Client_Public_API_.md @@ -17,8 +17,8 @@ graph LR Service_Modules -- "uses" --> Utility_Functions HTTP_Client_Transport_Layer -- "uses" --> Configuration_Management HTTP_Client_Transport_Layer -- "uses" --> Error_Handling - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/docs/architecture/Hooks_Extensibility.md b/docs/architecture/Hooks_Extensibility.md new file mode 100644 index 0000000..1ee6e91 --- /dev/null +++ b/docs/architecture/Hooks_Extensibility.md @@ -0,0 +1,50 @@ +```mermaid +graph LR + Hook_Contexts_DTOs_["Hook Contexts (DTOs)"] + Hook_Interface["Hook Interface"] + SDK_Hooks_Orchestrator["SDK Hooks Orchestrator"] + Hook_Contexts_DTOs_ -- "provides data to" --> Hook_Interface + SDK_Hooks_Orchestrator -- "interacts with" --> Hook_Contexts_DTOs_ + SDK_Hooks_Orchestrator -- "orchestrates" --> Hook_Interface + Hook_Interface -- "receives" --> Hook_Contexts_DTOs_ +``` + +[![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) + +## Details + +Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. + +### Hook Contexts (DTOs) +A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass relevant data and state through different stages of the API request/response lifecycle. These contexts provide the necessary information for hooks to operate on. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.BeforeRequestContext` (33:41) +- `friendli_core._hooks.types.AfterSuccessContext` (44:52) +- `friendli_core._hooks.types.AfterErrorContext` (55:63) + + +### Hook Interface +Defines the abstract interface or base class that custom hooks must implement. It establishes the contract for various hook methods (e.g., `before_request`, `after_success`, `after_error`), ensuring a consistent extensibility point for SDK users. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.Hooks` (99:114) + + +### SDK Hooks Orchestrator +The central manager responsible for registering, storing, and orchestrating the execution of various custom hooks at the appropriate stages of the SDK's request/response lifecycle. It acts as a facade for the entire hooks mechanism. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.sdkhooks.SDKHooks` (21:78) + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/Platform_Abstractions.md b/docs/architecture/Platform_Abstractions.md index 042b3b3..0dc9c08 100644 --- a/docs/architecture/Platform_Abstractions.md +++ b/docs/architecture/Platform_Abstractions.md @@ -5,7 +5,7 @@ graph LR Serverless_Client["Serverless Client"] Dedicated_Client -- "implements" --> Platform_Abstractions Serverless_Client -- "implements" --> Platform_Abstractions - click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) @@ -20,7 +20,7 @@ Defines the foundational base structures and interfaces that enable the SDK to a **Related Classes/Methods**: -- `friendli_core.basesdk:BaseSDK` (19:106) +- `friendli_core.basesdk:BaseSDK` (19:106) ### Dedicated Client @@ -29,9 +29,9 @@ A concrete implementation of the `Platform Abstractions` tailored specifically f **Related Classes/Methods**: -- `friendli_core.dedicated:BaseDedicated` (24:32) -- `friendli_core.dedicated:SyncDedicated` (35:49) -- `friendli_core.dedicated:AsyncDedicated` (52:66) +- `friendli_core.dedicated:BaseDedicated` (24:32) +- `friendli_core.dedicated:SyncDedicated` (35:49) +- `friendli_core.dedicated:AsyncDedicated` (52:66) ### Serverless Client @@ -40,9 +40,9 @@ A concrete implementation of the `Platform Abstractions` designed for interactin **Related Classes/Methods**: -- `friendli_core.serverless:BaseServerless` (24:32) -- `friendli_core.serverless:SyncServerless` (35:49) -- `friendli_core.serverless:AsyncServerless` (52:68) +- `friendli_core.serverless:BaseServerless` (24:32) +- `friendli_core.serverless:SyncServerless` (35:49) +- `friendli_core.serverless:AsyncServerless` (52:68) diff --git a/docs/architecture/SDK_Core.md b/docs/architecture/SDK_Core.md index 7bd9809..0aa48b1 100644 --- a/docs/architecture/SDK_Core.md +++ b/docs/architecture/SDK_Core.md @@ -26,9 +26,9 @@ graph LR Error_Handling -- "defines error types for" --> Service_Modules Utility_Functions -- "provides helpers to" --> SDK_Core Utility_Functions -- "provides helpers to" --> Service_Modules - click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Error_Handling.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) diff --git a/docs/architecture/Service_Modules.md b/docs/architecture/Service_Modules.md index 5184731..3a387b3 100644 --- a/docs/architecture/Service_Modules.md +++ b/docs/architecture/Service_Modules.md @@ -9,7 +9,7 @@ graph LR Service_Modules -- "invokes" --> JSON_Unmarshalling_Utility Service_Modules -- "interacts with" --> Event_Streaming_Utility Service_Modules -- "utilizes" --> Hook_Context_Management - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.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) @@ -24,14 +24,14 @@ These modules encapsulate the core API domain logic for specific functionalities **Related Classes/Methods**: -- `friendli_core.chat.SyncChat` (18:372) -- `friendli_core.chat.AsyncChat` (375:729) -- `friendli_core.completions.SyncCompletions` (18:194) -- `friendli_core.completions.AsyncCompletions` (197:373) -- `friendli_core.dataset.SyncDataset` (19:1528) -- `friendli_core.dataset.AsyncDataset` (1531:3040) -- `friendli_core.image.SyncImage` (18:118) -- `friendli_core.image.AsyncImage` (121:221) +- `friendli_core.chat.SyncChat` (18:372) +- `friendli_core.chat.AsyncChat` (375:729) +- `friendli_core.completions.SyncCompletions` (18:194) +- `friendli_core.completions.AsyncCompletions` (197:373) +- `friendli_core.dataset.SyncDataset` (19:1528) +- `friendli_core.dataset.AsyncDataset` (1531:3040) +- `friendli_core.image.SyncImage` (18:118) +- `friendli_core.image.AsyncImage` (121:221) ### Security Utility @@ -40,7 +40,7 @@ Responsible for securely retrieving and managing API credentials, typically from **Related Classes/Methods**: -- `friendli_core.utils.security.get_security_from_env` (57:69) +- `friendli_core.utils.security.get_security_from_env` (57:69) ### JSON Unmarshalling Utility @@ -49,7 +49,7 @@ Handles the deserialization of JSON responses received from the Friendli API int **Related Classes/Methods**: -- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) ### Event Streaming Utility @@ -58,8 +58,8 @@ Provides mechanisms for processing and managing streaming responses from the API **Related Classes/Methods**: -- `friendli_core.utils.eventstreaming.EventStream` (19:42) -- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) +- `friendli_core.utils.eventstreaming.EventStream` (19:42) +- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) ### Hook Context Management @@ -68,7 +68,7 @@ Manages an extensibility mechanism that allows developers to inject custom logic **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.HookContext` (11:30) diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 0fd781d..90e78bb 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -12,11 +12,12 @@ graph LR SDK_Core -- "integrates and consumes" --> Hooks_Extensibility Service_Modules -- "utilize" --> SDK_Core Service_Modules -- "rely on" --> Data_Models_Error_Handling - click Friendli_Client_Public_API_ href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" - click SDK_Core href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" - click Service_Modules href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" - click Data_Models_Error_Handling href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" - click Platform_Abstractions href "https://github.com/friendliai/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.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) @@ -74,7 +75,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -88,4 +89,4 @@ Offers an extensible mechanism for injecting custom logic at various stages of t ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) - [on_boarding.md](./on_boarding.md) -_Last updated: 2025-07-26 05:04:17 UTC_ +_Last updated: 2025-07-26 20:36:23 UTC_ From 3d511e21833d2601fefe487ede8eedad117d7150 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 2 Aug 2025 20:36:11 +0000 Subject: [PATCH 07/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 9 +++------ .codeboarding/codeboarding_version.json | 2 +- docs/architecture/on_boarding.md | 2 +- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json index 20e610f..9e00910 100644 --- a/.codeboarding/Hooks_Extensibility.json +++ b/.codeboarding/Hooks_Extensibility.json @@ -29,8 +29,7 @@ "reference_start_line": 55, "reference_end_line": 63 } - ], - "can_expand": false + ] }, { "name": "Hook Interface", @@ -42,8 +41,7 @@ "reference_start_line": 99, "reference_end_line": 114 } - ], - "can_expand": false + ] }, { "name": "SDK Hooks Orchestrator", @@ -55,8 +53,7 @@ "reference_start_line": 21, "reference_end_line": 78 } - ], - "can_expand": true + ] } ], "components_relations": [ diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index b32a4a8..f71b910 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "b40eabdc552d1974ad77c8ff8bd045d3985fb7fc", + "commit_hash": "46ff1e4ea0a7512e7d24a67e830ecc2a277795a5", "code_boarding_version": "0.1.0" } diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 90e78bb..887d8fd 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -89,4 +89,4 @@ Offers an extensible mechanism for injecting custom logic at various stages of t ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) - [on_boarding.md](./on_boarding.md) -_Last updated: 2025-07-26 20:36:23 UTC_ +_Last updated: 2025-08-02 20:36:11 UTC_ From bcf5e5cf0c7d2410e2be829f5e23c32ec7e22f62 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 9 Aug 2025 20:32:09 +0000 Subject: [PATCH 08/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Data_Models_Error_Handling.md | 12 ++++----- .codeboarding/Friendli_Client_Public_API_.md | 12 ++++----- .codeboarding/Hooks_Extensibility.md | 12 ++++----- .codeboarding/Platform_Abstractions.md | 14 +++++----- .codeboarding/Service_Modules.md | 26 +++++++++---------- .codeboarding/codeboarding_version.json | 2 +- .../Data_Models_Error_Handling.md | 12 ++++----- .../Friendli_Client_Public_API_.md | 12 ++++----- docs/architecture/Hooks_Extensibility.md | 12 ++++----- docs/architecture/Platform_Abstractions.md | 14 +++++----- docs/architecture/Service_Modules.md | 26 +++++++++---------- docs/architecture/on_boarding.md | 2 +- 12 files changed, 78 insertions(+), 78 deletions(-) diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md index 6132c01..fd58533 100644 --- a/.codeboarding/Data_Models_Error_Handling.md +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -29,7 +29,7 @@ The central entry point for the SDK, responsible for managing authentication, se **Related Classes/Methods**: -- `friendli_core.client` (1:1) +- `friendli_core.client` ### Service Modules [[Expand]](./Service_Modules.md) @@ -50,8 +50,8 @@ Defines standardized data structures for all API requests and responses, ensurin **Related Classes/Methods**: -- `friendli_core.models` (1:1) -- `friendli_core.errors` (1:1) +- `friendli_core.models` +- `friendli_core.errors` ### Utility Functions @@ -60,7 +60,7 @@ Provides common helper functions for SDK-wide tasks such as JSON serialization/d **Related Classes/Methods**: -- `friendli_core.utils` (1:1) +- `friendli_core.utils` ### Examples and Documentation @@ -69,8 +69,8 @@ Comprises practical code examples demonstrating how to effectively use the SDK's **Related Classes/Methods**: -- `examples` (1:1) -- `docs` (1:1) +- `examples` +- `docs` diff --git a/.codeboarding/Friendli_Client_Public_API_.md b/.codeboarding/Friendli_Client_Public_API_.md index d0fd9c6..f89eeac 100644 --- a/.codeboarding/Friendli_Client_Public_API_.md +++ b/.codeboarding/Friendli_Client_Public_API_.md @@ -44,7 +44,7 @@ Encapsulate the logic for interacting with specific API endpoints (e.g., chat, c - `friendli_core.chat` - `friendli_core.completions` -- `friendli_core.images` (1:1) +- `friendli_core.images` - `friendli_core.audio` @@ -54,7 +54,7 @@ Define the structure of data exchanged with the Friendli AI platform, including **Related Classes/Methods**: -- `friendli_core.models` (1:1) +- `friendli_core.models` ### HTTP Client/Transport Layer @@ -63,7 +63,7 @@ Handles the low-level HTTP communication with the Friendli AI platform. This inc **Related Classes/Methods**: -- `friendli_core.http_client` (1:1) +- `friendli_core.http_client` ### Error Handling [[Expand]](./Error_Handling.md) @@ -72,7 +72,7 @@ Manages and standardizes error responses from both the API and the network layer **Related Classes/Methods**: -- `friendli_core.errors` (1:1) +- `friendli_core.errors` ### Configuration Management @@ -81,7 +81,7 @@ Centralizes and manages SDK-wide configuration settings, such as API keys, base **Related Classes/Methods**: -- `friendli_core.config` (1:1) +- `friendli_core.config` ### Utility Functions @@ -90,7 +90,7 @@ Provides common helper functions and reusable functionalities that support vario **Related Classes/Methods**: -- `friendli_core.utils` (1:1) +- `friendli_core.utils` diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md index 1ee6e91..01f8a39 100644 --- a/.codeboarding/Hooks_Extensibility.md +++ b/.codeboarding/Hooks_Extensibility.md @@ -21,10 +21,10 @@ A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass rele **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) -- `friendli_core._hooks.types.BeforeRequestContext` (33:41) -- `friendli_core._hooks.types.AfterSuccessContext` (44:52) -- `friendli_core._hooks.types.AfterErrorContext` (55:63) +- `friendli_core._hooks.types.HookContext`:11-30 +- `friendli_core._hooks.types.BeforeRequestContext`:33-41 +- `friendli_core._hooks.types.AfterSuccessContext`:44-52 +- `friendli_core._hooks.types.AfterErrorContext`:55-63 ### Hook Interface @@ -33,7 +33,7 @@ Defines the abstract interface or base class that custom hooks must implement. I **Related Classes/Methods**: -- `friendli_core._hooks.types.Hooks` (99:114) +- `friendli_core._hooks.types.Hooks`:99-114 ### SDK Hooks Orchestrator @@ -42,7 +42,7 @@ The central manager responsible for registering, storing, and orchestrating the **Related Classes/Methods**: -- `friendli_core._hooks.sdkhooks.SDKHooks` (21:78) +- `friendli_core._hooks.sdkhooks.SDKHooks`:21-78 diff --git a/.codeboarding/Platform_Abstractions.md b/.codeboarding/Platform_Abstractions.md index 0dc9c08..4f917c1 100644 --- a/.codeboarding/Platform_Abstractions.md +++ b/.codeboarding/Platform_Abstractions.md @@ -20,7 +20,7 @@ Defines the foundational base structures and interfaces that enable the SDK to a **Related Classes/Methods**: -- `friendli_core.basesdk:BaseSDK` (19:106) +- `friendli_core.basesdk:BaseSDK`:19-106 ### Dedicated Client @@ -29,9 +29,9 @@ A concrete implementation of the `Platform Abstractions` tailored specifically f **Related Classes/Methods**: -- `friendli_core.dedicated:BaseDedicated` (24:32) -- `friendli_core.dedicated:SyncDedicated` (35:49) -- `friendli_core.dedicated:AsyncDedicated` (52:66) +- `friendli_core.dedicated:BaseDedicated`:24-32 +- `friendli_core.dedicated:SyncDedicated`:35-49 +- `friendli_core.dedicated:AsyncDedicated`:52-66 ### Serverless Client @@ -40,9 +40,9 @@ A concrete implementation of the `Platform Abstractions` designed for interactin **Related Classes/Methods**: -- `friendli_core.serverless:BaseServerless` (24:32) -- `friendli_core.serverless:SyncServerless` (35:49) -- `friendli_core.serverless:AsyncServerless` (52:68) +- `friendli_core.serverless:BaseServerless`:24-32 +- `friendli_core.serverless:SyncServerless`:35-49 +- `friendli_core.serverless:AsyncServerless`:52-68 diff --git a/.codeboarding/Service_Modules.md b/.codeboarding/Service_Modules.md index 3a387b3..85bbcf0 100644 --- a/.codeboarding/Service_Modules.md +++ b/.codeboarding/Service_Modules.md @@ -24,14 +24,14 @@ These modules encapsulate the core API domain logic for specific functionalities **Related Classes/Methods**: -- `friendli_core.chat.SyncChat` (18:372) -- `friendli_core.chat.AsyncChat` (375:729) -- `friendli_core.completions.SyncCompletions` (18:194) -- `friendli_core.completions.AsyncCompletions` (197:373) -- `friendli_core.dataset.SyncDataset` (19:1528) -- `friendli_core.dataset.AsyncDataset` (1531:3040) -- `friendli_core.image.SyncImage` (18:118) -- `friendli_core.image.AsyncImage` (121:221) +- `friendli_core.chat.SyncChat`:18-372 +- `friendli_core.chat.AsyncChat`:375-729 +- `friendli_core.completions.SyncCompletions`:18-194 +- `friendli_core.completions.AsyncCompletions`:197-373 +- `friendli_core.dataset.SyncDataset`:19-1528 +- `friendli_core.dataset.AsyncDataset`:1531-3040 +- `friendli_core.image.SyncImage`:18-118 +- `friendli_core.image.AsyncImage`:121-221 ### Security Utility @@ -40,7 +40,7 @@ Responsible for securely retrieving and managing API credentials, typically from **Related Classes/Methods**: -- `friendli_core.utils.security.get_security_from_env` (57:69) +- `friendli_core.utils.security.get_security_from_env`:57-69 ### JSON Unmarshalling Utility @@ -49,7 +49,7 @@ Handles the deserialization of JSON responses received from the Friendli API int **Related Classes/Methods**: -- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response`:11-24 ### Event Streaming Utility @@ -58,8 +58,8 @@ Provides mechanisms for processing and managing streaming responses from the API **Related Classes/Methods**: -- `friendli_core.utils.eventstreaming.EventStream` (19:42) -- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) +- `friendli_core.utils.eventstreaming.EventStream`:19-42 +- `friendli_core.utils.eventstreaming.EventStreamAsync`:45-68 ### Hook Context Management @@ -68,7 +68,7 @@ Manages an extensibility mechanism that allows developers to inject custom logic **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.HookContext`:11-30 diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index f71b910..2108ede 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "46ff1e4ea0a7512e7d24a67e830ecc2a277795a5", + "commit_hash": "3d511e21833d2601fefe487ede8eedad117d7150", "code_boarding_version": "0.1.0" } diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md index 6132c01..fd58533 100644 --- a/docs/architecture/Data_Models_Error_Handling.md +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -29,7 +29,7 @@ The central entry point for the SDK, responsible for managing authentication, se **Related Classes/Methods**: -- `friendli_core.client` (1:1) +- `friendli_core.client` ### Service Modules [[Expand]](./Service_Modules.md) @@ -50,8 +50,8 @@ Defines standardized data structures for all API requests and responses, ensurin **Related Classes/Methods**: -- `friendli_core.models` (1:1) -- `friendli_core.errors` (1:1) +- `friendli_core.models` +- `friendli_core.errors` ### Utility Functions @@ -60,7 +60,7 @@ Provides common helper functions for SDK-wide tasks such as JSON serialization/d **Related Classes/Methods**: -- `friendli_core.utils` (1:1) +- `friendli_core.utils` ### Examples and Documentation @@ -69,8 +69,8 @@ Comprises practical code examples demonstrating how to effectively use the SDK's **Related Classes/Methods**: -- `examples` (1:1) -- `docs` (1:1) +- `examples` +- `docs` diff --git a/docs/architecture/Friendli_Client_Public_API_.md b/docs/architecture/Friendli_Client_Public_API_.md index d0fd9c6..f89eeac 100644 --- a/docs/architecture/Friendli_Client_Public_API_.md +++ b/docs/architecture/Friendli_Client_Public_API_.md @@ -44,7 +44,7 @@ Encapsulate the logic for interacting with specific API endpoints (e.g., chat, c - `friendli_core.chat` - `friendli_core.completions` -- `friendli_core.images` (1:1) +- `friendli_core.images` - `friendli_core.audio` @@ -54,7 +54,7 @@ Define the structure of data exchanged with the Friendli AI platform, including **Related Classes/Methods**: -- `friendli_core.models` (1:1) +- `friendli_core.models` ### HTTP Client/Transport Layer @@ -63,7 +63,7 @@ Handles the low-level HTTP communication with the Friendli AI platform. This inc **Related Classes/Methods**: -- `friendli_core.http_client` (1:1) +- `friendli_core.http_client` ### Error Handling [[Expand]](./Error_Handling.md) @@ -72,7 +72,7 @@ Manages and standardizes error responses from both the API and the network layer **Related Classes/Methods**: -- `friendli_core.errors` (1:1) +- `friendli_core.errors` ### Configuration Management @@ -81,7 +81,7 @@ Centralizes and manages SDK-wide configuration settings, such as API keys, base **Related Classes/Methods**: -- `friendli_core.config` (1:1) +- `friendli_core.config` ### Utility Functions @@ -90,7 +90,7 @@ Provides common helper functions and reusable functionalities that support vario **Related Classes/Methods**: -- `friendli_core.utils` (1:1) +- `friendli_core.utils` diff --git a/docs/architecture/Hooks_Extensibility.md b/docs/architecture/Hooks_Extensibility.md index 1ee6e91..01f8a39 100644 --- a/docs/architecture/Hooks_Extensibility.md +++ b/docs/architecture/Hooks_Extensibility.md @@ -21,10 +21,10 @@ A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass rele **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) -- `friendli_core._hooks.types.BeforeRequestContext` (33:41) -- `friendli_core._hooks.types.AfterSuccessContext` (44:52) -- `friendli_core._hooks.types.AfterErrorContext` (55:63) +- `friendli_core._hooks.types.HookContext`:11-30 +- `friendli_core._hooks.types.BeforeRequestContext`:33-41 +- `friendli_core._hooks.types.AfterSuccessContext`:44-52 +- `friendli_core._hooks.types.AfterErrorContext`:55-63 ### Hook Interface @@ -33,7 +33,7 @@ Defines the abstract interface or base class that custom hooks must implement. I **Related Classes/Methods**: -- `friendli_core._hooks.types.Hooks` (99:114) +- `friendli_core._hooks.types.Hooks`:99-114 ### SDK Hooks Orchestrator @@ -42,7 +42,7 @@ The central manager responsible for registering, storing, and orchestrating the **Related Classes/Methods**: -- `friendli_core._hooks.sdkhooks.SDKHooks` (21:78) +- `friendli_core._hooks.sdkhooks.SDKHooks`:21-78 diff --git a/docs/architecture/Platform_Abstractions.md b/docs/architecture/Platform_Abstractions.md index 0dc9c08..4f917c1 100644 --- a/docs/architecture/Platform_Abstractions.md +++ b/docs/architecture/Platform_Abstractions.md @@ -20,7 +20,7 @@ Defines the foundational base structures and interfaces that enable the SDK to a **Related Classes/Methods**: -- `friendli_core.basesdk:BaseSDK` (19:106) +- `friendli_core.basesdk:BaseSDK`:19-106 ### Dedicated Client @@ -29,9 +29,9 @@ A concrete implementation of the `Platform Abstractions` tailored specifically f **Related Classes/Methods**: -- `friendli_core.dedicated:BaseDedicated` (24:32) -- `friendli_core.dedicated:SyncDedicated` (35:49) -- `friendli_core.dedicated:AsyncDedicated` (52:66) +- `friendli_core.dedicated:BaseDedicated`:24-32 +- `friendli_core.dedicated:SyncDedicated`:35-49 +- `friendli_core.dedicated:AsyncDedicated`:52-66 ### Serverless Client @@ -40,9 +40,9 @@ A concrete implementation of the `Platform Abstractions` designed for interactin **Related Classes/Methods**: -- `friendli_core.serverless:BaseServerless` (24:32) -- `friendli_core.serverless:SyncServerless` (35:49) -- `friendli_core.serverless:AsyncServerless` (52:68) +- `friendli_core.serverless:BaseServerless`:24-32 +- `friendli_core.serverless:SyncServerless`:35-49 +- `friendli_core.serverless:AsyncServerless`:52-68 diff --git a/docs/architecture/Service_Modules.md b/docs/architecture/Service_Modules.md index 3a387b3..85bbcf0 100644 --- a/docs/architecture/Service_Modules.md +++ b/docs/architecture/Service_Modules.md @@ -24,14 +24,14 @@ These modules encapsulate the core API domain logic for specific functionalities **Related Classes/Methods**: -- `friendli_core.chat.SyncChat` (18:372) -- `friendli_core.chat.AsyncChat` (375:729) -- `friendli_core.completions.SyncCompletions` (18:194) -- `friendli_core.completions.AsyncCompletions` (197:373) -- `friendli_core.dataset.SyncDataset` (19:1528) -- `friendli_core.dataset.AsyncDataset` (1531:3040) -- `friendli_core.image.SyncImage` (18:118) -- `friendli_core.image.AsyncImage` (121:221) +- `friendli_core.chat.SyncChat`:18-372 +- `friendli_core.chat.AsyncChat`:375-729 +- `friendli_core.completions.SyncCompletions`:18-194 +- `friendli_core.completions.AsyncCompletions`:197-373 +- `friendli_core.dataset.SyncDataset`:19-1528 +- `friendli_core.dataset.AsyncDataset`:1531-3040 +- `friendli_core.image.SyncImage`:18-118 +- `friendli_core.image.AsyncImage`:121-221 ### Security Utility @@ -40,7 +40,7 @@ Responsible for securely retrieving and managing API credentials, typically from **Related Classes/Methods**: -- `friendli_core.utils.security.get_security_from_env` (57:69) +- `friendli_core.utils.security.get_security_from_env`:57-69 ### JSON Unmarshalling Utility @@ -49,7 +49,7 @@ Handles the deserialization of JSON responses received from the Friendli API int **Related Classes/Methods**: -- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response` (11:24) +- `friendli_core.utils.unmarshal_json_response.unmarshal_json_response`:11-24 ### Event Streaming Utility @@ -58,8 +58,8 @@ Provides mechanisms for processing and managing streaming responses from the API **Related Classes/Methods**: -- `friendli_core.utils.eventstreaming.EventStream` (19:42) -- `friendli_core.utils.eventstreaming.EventStreamAsync` (45:68) +- `friendli_core.utils.eventstreaming.EventStream`:19-42 +- `friendli_core.utils.eventstreaming.EventStreamAsync`:45-68 ### Hook Context Management @@ -68,7 +68,7 @@ Manages an extensibility mechanism that allows developers to inject custom logic **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext` (11:30) +- `friendli_core._hooks.types.HookContext`:11-30 diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 887d8fd..7ef214e 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -89,4 +89,4 @@ Offers an extensible mechanism for injecting custom logic at various stages of t ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) - [on_boarding.md](./on_boarding.md) -_Last updated: 2025-08-02 20:36:11 UTC_ +_Last updated: 2025-08-09 20:32:09 UTC_ From d83c27313cdf505edee75ce61634f35005d493a4 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 30 Aug 2025 20:26:36 +0000 Subject: [PATCH 09/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/codeboarding_version.json | 2 +- docs/architecture/on_boarding.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 2108ede..dfb0980 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "3d511e21833d2601fefe487ede8eedad117d7150", + "commit_hash": "bcf5e5cf0c7d2410e2be829f5e23c32ec7e22f62", "code_boarding_version": "0.1.0" } diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 7ef214e..7027d14 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -89,4 +89,4 @@ Offers an extensible mechanism for injecting custom logic at various stages of t ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) - [on_boarding.md](./on_boarding.md) -_Last updated: 2025-08-09 20:32:09 UTC_ +_Last updated: 2025-08-30 20:26:36 UTC_ From 48e1afec15c27522bf602d5aa8e9249b44a58b8c Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 6 Sep 2025 20:25:32 +0000 Subject: [PATCH 10/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Data_Models_Error_Handling.md | 2 +- .codeboarding/Friendli_Client_Public_API_.md | 2 +- .codeboarding/Hooks_Extensibility.md | 2 +- .codeboarding/Platform_Abstractions.md | 2 +- .codeboarding/SDK_Core.md | 2 +- .codeboarding/Service_Modules.md | 2 +- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/{on_boarding.md => overview.md} | 2 +- .../Data_Models_Error_Handling.md | 2 +- .../Friendli_Client_Public_API_.md | 2 +- docs/architecture/Hooks_Extensibility.md | 2 +- docs/architecture/Platform_Abstractions.md | 2 +- docs/architecture/SDK_Core.md | 2 +- docs/architecture/Service_Modules.md | 2 +- docs/architecture/on_boarding.md | 9 ++ docs/architecture/overview.md | 89 +++++++++++++++++++ 16 files changed, 112 insertions(+), 14 deletions(-) rename .codeboarding/{on_boarding.md => overview.md} (93%) create mode 100644 docs/architecture/overview.md diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md index fd58533..cad87f2 100644 --- a/.codeboarding/Data_Models_Error_Handling.md +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -17,7 +17,7 @@ graph LR click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) +[![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) ## Details diff --git a/.codeboarding/Friendli_Client_Public_API_.md b/.codeboarding/Friendli_Client_Public_API_.md index f89eeac..c16befd 100644 --- a/.codeboarding/Friendli_Client_Public_API_.md +++ b/.codeboarding/Friendli_Client_Public_API_.md @@ -21,7 +21,7 @@ graph LR click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) +[![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) ## Details diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md index 01f8a39..0264029 100644 --- a/.codeboarding/Hooks_Extensibility.md +++ b/.codeboarding/Hooks_Extensibility.md @@ -9,7 +9,7 @@ graph LR Hook_Interface -- "receives" --> Hook_Contexts_DTOs_ ``` -[![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) +[![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) ## Details diff --git a/.codeboarding/Platform_Abstractions.md b/.codeboarding/Platform_Abstractions.md index 4f917c1..ac695ea 100644 --- a/.codeboarding/Platform_Abstractions.md +++ b/.codeboarding/Platform_Abstractions.md @@ -8,7 +8,7 @@ graph LR click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) +[![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) ## Details diff --git a/.codeboarding/SDK_Core.md b/.codeboarding/SDK_Core.md index 0aa48b1..82a5f6b 100644 --- a/.codeboarding/SDK_Core.md +++ b/.codeboarding/SDK_Core.md @@ -31,7 +31,7 @@ graph LR click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) +[![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) ## Details diff --git a/.codeboarding/Service_Modules.md b/.codeboarding/Service_Modules.md index 85bbcf0..fd2e67b 100644 --- a/.codeboarding/Service_Modules.md +++ b/.codeboarding/Service_Modules.md @@ -12,7 +12,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.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) +[![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) ## Details diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index dfb0980..73ca660 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "bcf5e5cf0c7d2410e2be829f5e23c32ec7e22f62", + "commit_hash": "d83c27313cdf505edee75ce61634f35005d493a4", "code_boarding_version": "0.1.0" } diff --git a/.codeboarding/on_boarding.md b/.codeboarding/overview.md similarity index 93% rename from .codeboarding/on_boarding.md rename to .codeboarding/overview.md index 7a6e359..de05809 100644 --- a/.codeboarding/on_boarding.md +++ b/.codeboarding/overview.md @@ -20,7 +20,7 @@ graph LR click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.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) +[![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) ## Details diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md index fd58533..cad87f2 100644 --- a/docs/architecture/Data_Models_Error_Handling.md +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -17,7 +17,7 @@ graph LR click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.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) +[![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) ## Details diff --git a/docs/architecture/Friendli_Client_Public_API_.md b/docs/architecture/Friendli_Client_Public_API_.md index f89eeac..c16befd 100644 --- a/docs/architecture/Friendli_Client_Public_API_.md +++ b/docs/architecture/Friendli_Client_Public_API_.md @@ -21,7 +21,7 @@ graph LR click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) +[![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) ## Details diff --git a/docs/architecture/Hooks_Extensibility.md b/docs/architecture/Hooks_Extensibility.md index 01f8a39..0264029 100644 --- a/docs/architecture/Hooks_Extensibility.md +++ b/docs/architecture/Hooks_Extensibility.md @@ -9,7 +9,7 @@ graph LR Hook_Interface -- "receives" --> Hook_Contexts_DTOs_ ``` -[![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) +[![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) ## Details diff --git a/docs/architecture/Platform_Abstractions.md b/docs/architecture/Platform_Abstractions.md index 4f917c1..ac695ea 100644 --- a/docs/architecture/Platform_Abstractions.md +++ b/docs/architecture/Platform_Abstractions.md @@ -8,7 +8,7 @@ graph LR click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.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) +[![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) ## Details diff --git a/docs/architecture/SDK_Core.md b/docs/architecture/SDK_Core.md index 0aa48b1..82a5f6b 100644 --- a/docs/architecture/SDK_Core.md +++ b/docs/architecture/SDK_Core.md @@ -31,7 +31,7 @@ graph LR click Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Error_Handling.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) +[![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) ## Details diff --git a/docs/architecture/Service_Modules.md b/docs/architecture/Service_Modules.md index 85bbcf0..fd2e67b 100644 --- a/docs/architecture/Service_Modules.md +++ b/docs/architecture/Service_Modules.md @@ -12,7 +12,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.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) +[![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) ## Details diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 7027d14..8d742be 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -90,3 +90,12 @@ Offers an extensible mechanism for injecting custom logic at various stages of t - [on_boarding.md](./on_boarding.md) _Last updated: 2025-08-30 20:26:36 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-09-06 20:25:32 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md new file mode 100644 index 0000000..de05809 --- /dev/null +++ b/docs/architecture/overview.md @@ -0,0 +1,89 @@ +```mermaid +graph LR + Friendli_Client_Public_API_["Friendli Client (Public API)"] + SDK_Core["SDK Core"] + Service_Modules["Service Modules"] + Data_Models_Error_Handling["Data Models & Error Handling"] + Platform_Abstractions["Platform Abstractions"] + Hooks_Extensibility["Hooks & Extensibility"] + Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core + SDK_Core -- "utilizes" --> Data_Models_Error_Handling + SDK_Core -- "adapts behavior based on" --> Platform_Abstractions + SDK_Core -- "integrates and consumes" --> Hooks_Extensibility + Service_Modules -- "utilize" --> SDK_Core + Service_Modules -- "rely on" --> Data_Models_Error_Handling + click Friendli_Client_Public_API_ href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Friendli_Client_Public_API_.md" "Details" + click SDK_Core href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/SDK_Core.md" "Details" + click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" + click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" + click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" +``` + +[![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) + +## Details + +One paragraph explaining the functionality which is represented by this graph. What the main flow is and what is its purpose. + +### Friendli Client (Public API) [[Expand]](./Friendli_Client_Public_API_.md) +The primary entry point for end-users, offering a high-level, consistent interface for interacting with the Friendli AI platform, supporting both synchronous and asynchronous operations. + + +**Related Classes/Methods**: + +- `friendli_core.sdk` + + +### SDK Core [[Expand]](./SDK_Core.md) +The central orchestrator managing fundamental logic for API communication, request/response processing, and integrating foundational SDK abstractions and extensibility points. + + +**Related Classes/Methods**: + +- `friendli_core.basesdk` + + +### Service Modules [[Expand]](./Service_Modules.md) +Encapsulate specific API domains (e.g., chat, completions, datasets), providing high-level, domain-specific methods that simplify interactions with particular parts of the Friendli API. + + +**Related Classes/Methods**: + +- `friendli_core.chat` +- `friendli_core.completions` +- `friendli_core.dataset` +- `friendli_core.image` + + +### Data Models & Error Handling [[Expand]](./Data_Models_Error_Handling.md) +Defines standardized data structures for API requests and responses, along with a comprehensive set of error types, ensuring consistent data representation and robust error reporting. + + +**Related Classes/Methods**: + +- `friendli_core.models` + + +### Platform Abstractions [[Expand]](./Platform_Abstractions.md) +Provides base structures and interfaces tailored for different operational modes or deployment types within the Friendli platform, enabling the SDK to adapt its behavior to the target environment. + + +**Related Classes/Methods**: + +- `friendli_core.dedicated` +- `friendli_core.serverless` + + +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. + + +**Related Classes/Methods**: + +- `friendli_core._hooks` + + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) From b64fffca672b341c4af1d01e732cc3da79147f28 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 13 Sep 2025 20:27:42 +0000 Subject: [PATCH 11/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 312 ++++++++++++++++++++++++ .codeboarding/codeboarding_version.json | 4 +- .codeboarding/overview.md | 7 + docs/architecture/on_boarding.md | 9 + docs/architecture/overview.md | 7 + 5 files changed, 337 insertions(+), 2 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index f177c29..d206935 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -12,6 +12,11 @@ "reference_end_line": null } ], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/friendli.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/sdk.py" + ], "can_expand": true }, { @@ -25,6 +30,13 @@ "reference_end_line": null } ], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/httpclient.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/config.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/basesdk.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/httpclient.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/sdkconfiguration.py" + ], "can_expand": true }, { @@ -56,6 +68,48 @@ "reference_end_line": null } ], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/completions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/token.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/completions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/tool_assisted_chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/model.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/token.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/knowledge.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/completions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/endpoint.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/image.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/token.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/audio.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dataset/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dataset/dataset.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/file/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/file/file.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_serverless_chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/completions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/file.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_image.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_completions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/endpoint.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_serverless_token.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/image.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/model.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/toolassistedchat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/dataset.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/token.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_token.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_serverless_completions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_chat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/knowledge.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/audio.py" + ], "can_expand": true }, { @@ -69,6 +123,223 @@ "reference_end_line": 0 } ], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/models.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/types.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerdetokenizationop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/splitinfo.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedgetendpointstatusop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/createdatasetrequest.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformat.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompletionstreamsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatusparameter.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionsbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/no_response_error.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreambodywithtokens.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatlogprobscontent.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointupdatebody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listsplitsresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/textcontent.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containertokenizationop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcreateendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/inferencedeploymenterrorcode.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionscompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformattext.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedaudiotranscriptionsop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/assistantmessagetoolcallfunction.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatcompletionstreambody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsdedicatedbodywithprompt.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionschoice.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstokenizationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatusage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionslogprobs.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/pricingmodel.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsbodywithprompt.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_infoop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompletionbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedtoolcallresult.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsdedicatedbodywithtokens.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionsstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/functionality.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionscompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstokenizationop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/security.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/function.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listversionsresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsstreamsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionsstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamdedicatedbodywithprompt.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/friendlicoreerror.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedaudiotranscriptionsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/usermessage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedwakeendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedfunctionresult.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointwandbartifactcreatebody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/b64imageitem.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerdetokenizationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatjsonschema.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/httpvalidationerror.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessmodellistsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointwandbartifactcreateop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/usermessagecontentmultimodal.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedupdateendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/acceleratorrequirement.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/videodata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatusdata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/functionresult.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedimagegeneratesuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessdetokenizationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatjsonschemaschema.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessknowledgeretrievalbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddatasetmodalitytype.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedterminateendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedtoolassistedchattoken.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsserverlessbodywithprompt.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/filegetdownloadurlresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listdatasetsresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointversionhistoryresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_splitop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_download_urlop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatstreamop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolcallresult.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddatasetmodality.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatlogprobs.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatuserror.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedimagegenerationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/autoscalingpolicy.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedgetendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_versionsop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamdedicatedbodywithtokens.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamserverlessbodywithprompt.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedcompletionschoice.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_versionop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolassistedchattool.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedtokenizationop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionssuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamserverlessbodywithtokens.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/add_samplesop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletesuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_samplesop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/imagecontent.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/audiocontent.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointstatus.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessdetokenizationsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolmessage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessdetokenizationop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionsbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/usage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containertokenizationsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/sdkerror.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessknowledgeretrieveop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatcompletionbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_versionop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/inferencedeploymentstatus.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedrestartendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_datasetsop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamoptions.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedtoolassistedchattoolstatus.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/assistantmessagetoolcall.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_datasetop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedtokenizationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedgetendpointversionhistoryop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionscompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/imagedata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedaudiotranscriptionbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletionstreambody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatregex.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/create_versionop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/knowledgeretrievedchunk.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/otherbuiltintool.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/fileinituploadrequest.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointcreatebody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/systemmessage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatchoicedelta.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionsstreambody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointwandbartifactcreateresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerimagesgenerateop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddeleteendpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatchoicemessage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatlogprobscontenttoplogprob.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/tool.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_splitop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/fileinituploadresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/urlimageitem.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/servervadchunkingstrategy.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatcompletionbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/create_splitop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/message.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/filebuiltintool.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatchoice.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatcompletionbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletionbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointlistresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsbodywithtokens.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/endpointsimplescaleconfig.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddetokenizationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerimagegeneratesuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompletionstreambody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/deletesamplesresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatcompletebodytoolchoicefunction.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsstreambody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containertokenizationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreambodywithprompt.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerimagegenerationbody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddetokenizationop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_splitsop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstokenizationsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/datasetinfo.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/modelcatalogresponseitem.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessknowledgeretrievalsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatusfile.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatcompletebodytoolchoice.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/tokensequence.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedlistendpointsop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedimagesgenerateop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/addsamplesresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/body_upload_raw_samples.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedsleependpointop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_samplesop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsserverlessbodywithtokens.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedtokenizationsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatcompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatchoice.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/videocontent.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatcompleteop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletionstreamsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listsamplesresponse.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/complete_uploadop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesspriceunittype.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/versioninfo.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/endpointadvancedconfig.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/assistantmessage.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointspec.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_datasetop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatjsonobject.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responsevalidationerror.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/upload_raw_samplesop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionsstreambody.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerdetokenizationsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/accountfilestatus.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/audiodata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/validationerror.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddetokenizationsuccess.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/create_datasetop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/init_uploadop.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatchoice.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatdata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/fileinfo.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedcompletiondata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/types/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/types/basemodel.py" + ], "can_expand": true }, { @@ -88,6 +359,11 @@ "reference_end_line": null } ], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/dedicated.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/container.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/serverless.py" + ], "can_expand": true }, { @@ -101,7 +377,43 @@ "reference_end_line": 0 } ], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/sdkhooks.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/registration.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/types.py" + ], "can_expand": true + }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [ + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/utils.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_version.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/metadata.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/__init__.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/forms.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/queryparams.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/serializers.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/security.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/datetimes.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/requestbodies.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/enums.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/url.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/retries.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/values.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/headers.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/logger.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/unmarshal_json_response.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/eventstreaming.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/annotations.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/scripts/prepare_readme.py", + "/home/ubuntu/CodeBoarding/repo/friendli-python/scripts/auto-fix.py" + ], + "can_expand": false } ], "components_relations": [ diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 73ca660..9b48129 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "d83c27313cdf505edee75ce61634f35005d493a4", - "code_boarding_version": "0.1.0" + "commit_hash": "48e1afec15c27522bf602d5aa8e9249b44a58b8c", + "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index de05809..cf6c60d 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -6,6 +6,7 @@ graph LR Data_Models_Error_Handling["Data Models & Error Handling"] Platform_Abstractions["Platform Abstractions"] Hooks_Extensibility["Hooks & Extensibility"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -84,6 +85,12 @@ Offers an extensible mechanism for injecting custom logic at various stages of t - `friendli_core._hooks` +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + +**Related Classes/Methods**: _None_ + ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 8d742be..4794f5d 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -99,3 +99,12 @@ _Last updated: 2025-08-30 20:26:36 UTC_ - [overview.md](./overview.md) _Last updated: 2025-09-06 20:25:32 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-09-13 20:27:42 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index de05809..cf6c60d 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -6,6 +6,7 @@ graph LR Data_Models_Error_Handling["Data Models & Error Handling"] Platform_Abstractions["Platform Abstractions"] Hooks_Extensibility["Hooks & Extensibility"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -84,6 +85,12 @@ Offers an extensible mechanism for injecting custom logic at various stages of t - `friendli_core._hooks` +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + +**Related Classes/Methods**: _None_ + ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) From 47865282250c727f1bd2ee10aa2a6a9d8a48037d Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 20 Sep 2025 20:28:14 +0000 Subject: [PATCH 12/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Data_Models_Error_Handling.md | 2 +- .codeboarding/analysis.json | 589 +++++++++--------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 + .../Data_Models_Error_Handling.md | 2 +- docs/architecture/on_boarding.md | 9 + docs/architecture/overview.md | 7 + 7 files changed, 323 insertions(+), 295 deletions(-) diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md index cad87f2..44e7898 100644 --- a/.codeboarding/Data_Models_Error_Handling.md +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -70,7 +70,7 @@ Comprises practical code examples demonstrating how to effectively use the SDK's **Related Classes/Methods**: - `examples` -- `docs` +- `docs` diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index d206935..addb9bb 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -13,9 +13,8 @@ } ], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/friendli.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/sdk.py" + "src/friendli/friendli.py", + "src/friendli/__init__.py" ], "can_expand": true }, @@ -31,11 +30,13 @@ } ], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/httpclient.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/config.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/basesdk.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/httpclient.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/sdkconfiguration.py" + "src/friendli/httpclient.py", + "src/friendli/config.py", + "src/friendli_core/__init__.py", + "src/friendli_core/endpoint.py", + "src/friendli_core/basesdk.py", + "src/friendli_core/httpclient.py", + "src/friendli_core/sdkconfiguration.py" ], "can_expand": true }, @@ -69,46 +70,28 @@ } ], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/completions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/container/token.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/completions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/tool_assisted_chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/model.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/token.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/serverless/knowledge.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/completions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/endpoint.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/image.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/token.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dedicated/audio.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dataset/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/dataset/dataset.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/file/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/file/file.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_serverless_chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/completions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/file.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_image.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_completions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/endpoint.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_serverless_token.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/image.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/model.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/toolassistedchat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/dataset.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/token.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_token.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_serverless_completions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/friendlicore_chat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/knowledge.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/audio.py" + "src/friendli/container/completions.py", + "src/friendli/container/__init__.py", + "src/friendli/container/chat.py", + "src/friendli/container/token.py", + "src/friendli/dataset/__init__.py", + "src/friendli/dataset/dataset.py", + "src/friendli/file/__init__.py", + "src/friendli/file/file.py", + "src/friendli_core/completions.py", + "src/friendli_core/file.py", + "src/friendli_core/container.py", + "src/friendli_core/chat.py", + "src/friendli_core/friendlicore_image.py", + "src/friendli_core/friendlicore_completions.py", + "src/friendli_core/image.py", + "src/friendli_core/toolassistedchat.py", + "src/friendli_core/dataset.py", + "src/friendli_core/token.py", + "src/friendli_core/friendlicore_token.py", + "src/friendli_core/friendlicore_chat.py", + "src/friendli_core/knowledge.py", + "src/friendli_core/audio.py" ], "can_expand": true }, @@ -124,221 +107,221 @@ } ], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/models.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/types.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerdetokenizationop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/splitinfo.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedgetendpointstatusop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/createdatasetrequest.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformat.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompletionstreamsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatusparameter.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionsbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/no_response_error.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreambodywithtokens.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatlogprobscontent.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointupdatebody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listsplitsresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/textcontent.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containertokenizationop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcreateendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/inferencedeploymenterrorcode.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionscompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformattext.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedaudiotranscriptionsop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/assistantmessagetoolcallfunction.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatcompletionstreambody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsdedicatedbodywithprompt.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionschoice.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstokenizationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatusage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionslogprobs.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/pricingmodel.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsbodywithprompt.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_infoop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompletionbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedtoolcallresult.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsdedicatedbodywithtokens.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionsstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/functionality.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionscompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstokenizationop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/security.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/function.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listversionsresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsstreamsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionsstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamdedicatedbodywithprompt.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/friendlicoreerror.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedaudiotranscriptionsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/usermessage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedwakeendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedfunctionresult.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointwandbartifactcreatebody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/b64imageitem.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerdetokenizationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatjsonschema.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/httpvalidationerror.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessmodellistsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointwandbartifactcreateop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/usermessagecontentmultimodal.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedupdateendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/acceleratorrequirement.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/videodata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatusdata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/functionresult.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedimagegeneratesuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessdetokenizationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatjsonschemaschema.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessknowledgeretrievalbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddatasetmodalitytype.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedterminateendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedtoolassistedchattoken.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsserverlessbodywithprompt.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/filegetdownloadurlresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listdatasetsresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointversionhistoryresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_splitop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_download_urlop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatstreamop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolcallresult.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddatasetmodality.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatlogprobs.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatuserror.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedimagegenerationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/autoscalingpolicy.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedgetendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_versionsop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamdedicatedbodywithtokens.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamserverlessbodywithprompt.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedcompletionschoice.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_versionop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolassistedchattool.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedtokenizationop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionssuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreamserverlessbodywithtokens.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/add_samplesop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletesuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_samplesop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/imagecontent.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/audiocontent.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointstatus.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessdetokenizationsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolmessage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessdetokenizationop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionsbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/usage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containertokenizationsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/sdkerror.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessknowledgeretrieveop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatcompletionbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_versionop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/inferencedeploymentstatus.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedrestartendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_datasetsop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamoptions.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedtoolassistedchattoolstatus.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/assistantmessagetoolcall.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_datasetop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedtokenizationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedgetendpointversionhistoryop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionscompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/imagedata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedaudiotranscriptionbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletionstreambody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatregex.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/create_versionop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/knowledgeretrievedchunk.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/otherbuiltintool.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/fileinituploadrequest.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointcreatebody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/systemmessage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatchoicedelta.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesscompletionsstreambody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointwandbartifactcreateresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerimagesgenerateop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddeleteendpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatchoicemessage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatlogprobscontenttoplogprob.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/tool.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/delete_splitop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/fileinituploadresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/urlimageitem.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/servervadchunkingstrategy.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatcompletionbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/create_splitop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/message.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/filebuiltintool.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatchoice.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatcompletionbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletionbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointlistresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsbodywithtokens.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/endpointsimplescaleconfig.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddetokenizationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerimagegeneratesuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstoolassistedchatcompletionstreambody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/deletesamplesresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatcompletebodytoolchoicefunction.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containercompletionsstreambody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containertokenizationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsstreambodywithprompt.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerimagegenerationbody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddetokenizationop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_splitsop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesstokenizationsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/datasetinfo.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/modelcatalogresponseitem.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlessknowledgeretrievalsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/toolstatusfile.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/chatcompletebodytoolchoice.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/tokensequence.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedlistendpointsop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedimagesgenerateop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/addsamplesresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/body_upload_raw_samples.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedsleependpointop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/list_samplesop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/completionsserverlessbodywithtokens.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedtokenizationsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesschatcompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatchoice.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/videocontent.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedchatcompleteop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerchatcompletionstreamsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/listsamplesresponse.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/complete_uploadop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/serverlesspriceunittype.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/versioninfo.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/endpointadvancedconfig.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/assistantmessage.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedendpointspec.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/get_datasetop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responseformatjsonobject.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/responsevalidationerror.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/upload_raw_samplesop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicatedcompletionsstreambody.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/containerdetokenizationsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/accountfilestatus.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/audiodata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/validationerror.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/dedicateddetokenizationsuccess.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/create_datasetop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/init_uploadop.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatchoice.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedchatdata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/fileinfo.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/models/streamedcompletiondata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/types/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/types/basemodel.py" + "src/friendli/models.py", + "src/friendli/types.py", + "src/friendli_core/model.py", + "src/friendli_core/models/containerdetokenizationop.py", + "src/friendli_core/models/splitinfo.py", + "src/friendli_core/models/dedicatedgetendpointstatusop.py", + "src/friendli_core/models/createdatasetrequest.py", + "src/friendli_core/models/responseformat.py", + "src/friendli_core/models/serverlesstoolassistedchatcompletionstreamsuccess.py", + "src/friendli_core/models/toolstatusparameter.py", + "src/friendli_core/models/serverlesscompletionsbody.py", + "src/friendli_core/models/no_response_error.py", + "src/friendli_core/models/completionsstreambodywithtokens.py", + "src/friendli_core/models/__init__.py", + "src/friendli_core/models/containercompletionsstreamop.py", + "src/friendli_core/models/chatlogprobscontent.py", + "src/friendli_core/models/dedicatedendpointupdatebody.py", + "src/friendli_core/models/listsplitsresponse.py", + "src/friendli_core/models/textcontent.py", + "src/friendli_core/models/containertokenizationop.py", + "src/friendli_core/models/dedicatedcreateendpointop.py", + "src/friendli_core/models/inferencedeploymenterrorcode.py", + "src/friendli_core/models/dedicatedchatstreamop.py", + "src/friendli_core/models/containercompletionscompleteop.py", + "src/friendli_core/models/responseformattext.py", + "src/friendli_core/models/dedicatedaudiotranscriptionsop.py", + "src/friendli_core/models/assistantmessagetoolcallfunction.py", + "src/friendli_core/models/serverlesschatcompletionstreambody.py", + "src/friendli_core/models/completionsdedicatedbodywithprompt.py", + "src/friendli_core/models/completionschoice.py", + "src/friendli_core/models/serverlesstokenizationbody.py", + "src/friendli_core/models/chatusage.py", + "src/friendli_core/models/completionslogprobs.py", + "src/friendli_core/models/pricingmodel.py", + "src/friendli_core/models/completionsbodywithprompt.py", + "src/friendli_core/models/get_infoop.py", + "src/friendli_core/models/serverlesstoolassistedchatcompletionbody.py", + "src/friendli_core/models/streamedtoolcallresult.py", + "src/friendli_core/models/completionsdedicatedbodywithtokens.py", + "src/friendli_core/models/serverlesscompletionsstreamop.py", + "src/friendli_core/models/containercompletionsbody.py", + "src/friendli_core/models/functionality.py", + "src/friendli_core/models/serverlesscompletionscompleteop.py", + "src/friendli_core/models/serverlesstokenizationop.py", + "src/friendli_core/models/security.py", + "src/friendli_core/models/function.py", + "src/friendli_core/models/listversionsresponse.py", + "src/friendli_core/models/containercompletionsstreamsuccess.py", + "src/friendli_core/models/dedicatedcompletionsstreamop.py", + "src/friendli_core/models/completionsstreamdedicatedbodywithprompt.py", + "src/friendli_core/models/friendlicoreerror.py", + "src/friendli_core/models/dedicatedaudiotranscriptionsuccess.py", + "src/friendli_core/models/usermessage.py", + "src/friendli_core/models/dedicatedwakeendpointop.py", + "src/friendli_core/models/streamedfunctionresult.py", + "src/friendli_core/models/dedicatedendpointwandbartifactcreatebody.py", + "src/friendli_core/models/b64imageitem.py", + "src/friendli_core/models/containerdetokenizationbody.py", + "src/friendli_core/models/responseformatjsonschema.py", + "src/friendli_core/models/httpvalidationerror.py", + "src/friendli_core/models/serverlessmodellistsuccess.py", + "src/friendli_core/models/dedicatedendpointwandbartifactcreateop.py", + "src/friendli_core/models/usermessagecontentmultimodal.py", + "src/friendli_core/models/dedicatedupdateendpointop.py", + "src/friendli_core/models/acceleratorrequirement.py", + "src/friendli_core/models/serverlesschatstreamop.py", + "src/friendli_core/models/videodata.py", + "src/friendli_core/models/toolstatusdata.py", + "src/friendli_core/models/functionresult.py", + "src/friendli_core/models/dedicatedimagegeneratesuccess.py", + "src/friendli_core/models/serverlessdetokenizationbody.py", + "src/friendli_core/models/containerchatstreamop.py", + "src/friendli_core/models/responseformatjsonschemaschema.py", + "src/friendli_core/models/serverlessknowledgeretrievalbody.py", + "src/friendli_core/models/dedicateddatasetmodalitytype.py", + "src/friendli_core/models/dedicatedterminateendpointop.py", + "src/friendli_core/models/streamedtoolassistedchattoken.py", + "src/friendli_core/models/completionsserverlessbodywithprompt.py", + "src/friendli_core/models/filegetdownloadurlresponse.py", + "src/friendli_core/models/listdatasetsresponse.py", + "src/friendli_core/models/dedicatedendpointversionhistoryresponse.py", + "src/friendli_core/models/get_splitop.py", + "src/friendli_core/models/get_download_urlop.py", + "src/friendli_core/models/serverlesstoolassistedchatstreamop.py", + "src/friendli_core/models/toolcallresult.py", + "src/friendli_core/models/dedicateddatasetmodality.py", + "src/friendli_core/models/chatlogprobs.py", + "src/friendli_core/models/toolstatuserror.py", + "src/friendli_core/models/dedicatedimagegenerationbody.py", + "src/friendli_core/models/autoscalingpolicy.py", + "src/friendli_core/models/dedicatedgetendpointop.py", + "src/friendli_core/models/list_versionsop.py", + "src/friendli_core/models/completionsstreamdedicatedbodywithtokens.py", + "src/friendli_core/models/completionsstreamserverlessbodywithprompt.py", + "src/friendli_core/models/streamedcompletionschoice.py", + "src/friendli_core/models/get_versionop.py", + "src/friendli_core/models/toolassistedchattool.py", + "src/friendli_core/models/dedicatedtokenizationop.py", + "src/friendli_core/models/containercompletionssuccess.py", + "src/friendli_core/models/completionsstreamserverlessbodywithtokens.py", + "src/friendli_core/models/add_samplesop.py", + "src/friendli_core/models/containerchatcompletesuccess.py", + "src/friendli_core/models/delete_samplesop.py", + "src/friendli_core/models/imagecontent.py", + "src/friendli_core/models/audiocontent.py", + "src/friendli_core/models/dedicatedendpointstatus.py", + "src/friendli_core/models/serverlessdetokenizationsuccess.py", + "src/friendli_core/models/toolmessage.py", + "src/friendli_core/models/serverlessdetokenizationop.py", + "src/friendli_core/models/dedicatedcompletionsbody.py", + "src/friendli_core/models/usage.py", + "src/friendli_core/models/containertokenizationsuccess.py", + "src/friendli_core/models/sdkerror.py", + "src/friendli_core/models/serverlessknowledgeretrieveop.py", + "src/friendli_core/models/dedicatedchatcompletionbody.py", + "src/friendli_core/models/delete_versionop.py", + "src/friendli_core/models/inferencedeploymentstatus.py", + "src/friendli_core/models/serverlesstoolassistedchatcompleteop.py", + "src/friendli_core/models/dedicatedrestartendpointop.py", + "src/friendli_core/models/list_datasetsop.py", + "src/friendli_core/models/streamoptions.py", + "src/friendli_core/models/streamedtoolassistedchattoolstatus.py", + "src/friendli_core/models/assistantmessagetoolcall.py", + "src/friendli_core/models/delete_datasetop.py", + "src/friendli_core/models/dedicatedtokenizationbody.py", + "src/friendli_core/models/dedicatedgetendpointversionhistoryop.py", + "src/friendli_core/models/dedicatedcompletionscompleteop.py", + "src/friendli_core/models/imagedata.py", + "src/friendli_core/models/dedicatedaudiotranscriptionbody.py", + "src/friendli_core/models/containerchatcompletionstreambody.py", + "src/friendli_core/models/responseformatregex.py", + "src/friendli_core/models/create_versionop.py", + "src/friendli_core/models/knowledgeretrievedchunk.py", + "src/friendli_core/models/otherbuiltintool.py", + "src/friendli_core/models/fileinituploadrequest.py", + "src/friendli_core/models/dedicatedendpointcreatebody.py", + "src/friendli_core/models/systemmessage.py", + "src/friendli_core/models/streamedchatchoicedelta.py", + "src/friendli_core/models/serverlesscompletionsstreambody.py", + "src/friendli_core/models/dedicatedendpointwandbartifactcreateresponse.py", + "src/friendli_core/models/containerimagesgenerateop.py", + "src/friendli_core/models/dedicateddeleteendpointop.py", + "src/friendli_core/models/chatchoicemessage.py", + "src/friendli_core/models/chatlogprobscontenttoplogprob.py", + "src/friendli_core/models/tool.py", + "src/friendli_core/models/delete_splitop.py", + "src/friendli_core/models/fileinituploadresponse.py", + "src/friendli_core/models/urlimageitem.py", + "src/friendli_core/models/servervadchunkingstrategy.py", + "src/friendli_core/models/serverlesschatcompletionbody.py", + "src/friendli_core/models/create_splitop.py", + "src/friendli_core/models/message.py", + "src/friendli_core/models/filebuiltintool.py", + "src/friendli_core/models/chatchoice.py", + "src/friendli_core/models/dedicatedchatcompletionstreambody.py", + "src/friendli_core/models/containerchatcompletionbody.py", + "src/friendli_core/models/dedicatedendpointlistresponse.py", + "src/friendli_core/models/completionsbodywithtokens.py", + "src/friendli_core/models/endpointsimplescaleconfig.py", + "src/friendli_core/models/dedicateddetokenizationbody.py", + "src/friendli_core/models/containerimagegeneratesuccess.py", + "src/friendli_core/models/serverlesstoolassistedchatcompletionstreambody.py", + "src/friendli_core/models/deletesamplesresponse.py", + "src/friendli_core/models/chatcompletebodytoolchoicefunction.py", + "src/friendli_core/models/containercompletionsstreambody.py", + "src/friendli_core/models/containertokenizationbody.py", + "src/friendli_core/models/completionsstreambodywithprompt.py", + "src/friendli_core/models/containerimagegenerationbody.py", + "src/friendli_core/models/dedicateddetokenizationop.py", + "src/friendli_core/models/list_splitsop.py", + "src/friendli_core/models/serverlesstokenizationsuccess.py", + "src/friendli_core/models/datasetinfo.py", + "src/friendli_core/models/containerchatcompleteop.py", + "src/friendli_core/models/modelcatalogresponseitem.py", + "src/friendli_core/models/serverlessknowledgeretrievalsuccess.py", + "src/friendli_core/models/toolstatusfile.py", + "src/friendli_core/models/chatcompletebodytoolchoice.py", + "src/friendli_core/models/tokensequence.py", + "src/friendli_core/models/dedicatedlistendpointsop.py", + "src/friendli_core/models/dedicatedimagesgenerateop.py", + "src/friendli_core/models/addsamplesresponse.py", + "src/friendli_core/models/body_upload_raw_samples.py", + "src/friendli_core/models/dedicatedsleependpointop.py", + "src/friendli_core/models/list_samplesop.py", + "src/friendli_core/models/completionsserverlessbodywithtokens.py", + "src/friendli_core/models/dedicatedtokenizationsuccess.py", + "src/friendli_core/models/serverlesschatcompleteop.py", + "src/friendli_core/models/streamedchatchoice.py", + "src/friendli_core/models/videocontent.py", + "src/friendli_core/models/dedicatedchatcompleteop.py", + "src/friendli_core/models/containerchatcompletionstreamsuccess.py", + "src/friendli_core/models/listsamplesresponse.py", + "src/friendli_core/models/complete_uploadop.py", + "src/friendli_core/models/serverlesspriceunittype.py", + "src/friendli_core/models/versioninfo.py", + "src/friendli_core/models/endpointadvancedconfig.py", + "src/friendli_core/models/assistantmessage.py", + "src/friendli_core/models/dedicatedendpointspec.py", + "src/friendli_core/models/get_datasetop.py", + "src/friendli_core/models/responseformatjsonobject.py", + "src/friendli_core/models/responsevalidationerror.py", + "src/friendli_core/models/upload_raw_samplesop.py", + "src/friendli_core/models/dedicatedcompletionsstreambody.py", + "src/friendli_core/models/containerdetokenizationsuccess.py", + "src/friendli_core/models/accountfilestatus.py", + "src/friendli_core/models/audiodata.py", + "src/friendli_core/models/validationerror.py", + "src/friendli_core/models/dedicateddetokenizationsuccess.py", + "src/friendli_core/models/create_datasetop.py", + "src/friendli_core/models/init_uploadop.py", + "src/friendli_core/models/streamedchatdata.py", + "src/friendli_core/models/fileinfo.py", + "src/friendli_core/models/streamedcompletiondata.py", + "src/friendli_core/types/__init__.py", + "src/friendli_core/types/basemodel.py" ], "can_expand": true }, @@ -360,9 +343,25 @@ } ], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/dedicated.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/container.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/serverless.py" + "src/friendli/serverless/completions.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", + "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli_core/dedicated.py", + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/serverless.py", + "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true }, @@ -378,10 +377,10 @@ } ], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/sdkhooks.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/registration.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_hooks/types.py" + "src/friendli_core/_hooks/__init__.py", + "src/friendli_core/_hooks/sdkhooks.py", + "src/friendli_core/_hooks/registration.py", + "src/friendli_core/_hooks/types.py" ], "can_expand": true }, @@ -390,30 +389,36 @@ "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", "referenced_source_code": [], "assigned_files": [ - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli/utils.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/_version.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/metadata.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/__init__.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/forms.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/queryparams.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/serializers.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/security.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/datetimes.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/requestbodies.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/enums.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/url.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/retries.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/values.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/headers.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/logger.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/unmarshal_json_response.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/eventstreaming.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/utils/annotations.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/scripts/prepare_readme.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/scripts/auto-fix.py" + "src/friendli/utils.py", + "src/friendli_core/_version.py", + "src/friendli_core/utils/metadata.py", + "src/friendli_core/utils/__init__.py", + "src/friendli_core/utils/forms.py", + "src/friendli_core/utils/queryparams.py", + "src/friendli_core/utils/serializers.py", + "src/friendli_core/utils/security.py", + "src/friendli_core/utils/datetimes.py", + "src/friendli_core/utils/requestbodies.py", + "src/friendli_core/utils/enums.py", + "src/friendli_core/utils/url.py", + "src/friendli_core/utils/retries.py", + "src/friendli_core/utils/values.py", + "src/friendli_core/utils/headers.py", + "src/friendli_core/utils/logger.py", + "src/friendli_core/utils/unmarshal_json_response.py", + "src/friendli_core/utils/eventstreaming.py", + "src/friendli_core/utils/annotations.py", + "scripts/prepare_readme.py", + "scripts/auto-fix.py" ], "can_expand": false + }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false } ], "components_relations": [ diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 9b48129..1826475 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "48e1afec15c27522bf602d5aa8e9249b44a58b8c", + "commit_hash": "b64fffca672b341c4af1d01e732cc3da79147f28", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index cf6c60d..6fad7a9 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -7,6 +7,7 @@ graph LR Platform_Abstractions["Platform Abstractions"] Hooks_Extensibility["Hooks & Extensibility"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -89,6 +90,12 @@ Offers an extensible mechanism for injecting custom logic at various stages of t Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md index cad87f2..44e7898 100644 --- a/docs/architecture/Data_Models_Error_Handling.md +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -70,7 +70,7 @@ Comprises practical code examples demonstrating how to effectively use the SDK's **Related Classes/Methods**: - `examples` -- `docs` +- `docs` diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 4794f5d..535270d 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -108,3 +108,12 @@ _Last updated: 2025-09-06 20:25:32 UTC_ - [overview.md](./overview.md) _Last updated: 2025-09-13 20:27:42 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-09-20 20:28:14 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index cf6c60d..6fad7a9 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -7,6 +7,7 @@ graph LR Platform_Abstractions["Platform Abstractions"] Hooks_Extensibility["Hooks & Extensibility"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -89,6 +90,12 @@ Offers an extensible mechanism for injecting custom logic at various stages of t Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 071467ad6d4b26f39ca742a606531b75ec6ab2b7 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 27 Sep 2025 20:30:20 +0000 Subject: [PATCH 13/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 72 ++++++++++++++----------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++ docs/architecture/on_boarding.md | 9 ++++ docs/architecture/overview.md | 7 +++ 5 files changed, 64 insertions(+), 33 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index addb9bb..d63c497 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -13,8 +13,11 @@ } ], "assigned_files": [ + "/mnt/e/StartUp/friendli-python/src/friendli_core/sdk.py", "src/friendli/friendli.py", - "src/friendli/__init__.py" + "src/friendli/__init__.py", + "src/friendli/config.py", + "src/friendli_core/sdkconfiguration.py" ], "can_expand": true }, @@ -30,13 +33,11 @@ } ], "assigned_files": [ + "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", "src/friendli/httpclient.py", - "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/basesdk.py", - "src/friendli_core/httpclient.py", - "src/friendli_core/sdkconfiguration.py" + "src/friendli_core/_version.py", + "src/friendli_core/httpclient.py" ], "can_expand": true }, @@ -70,28 +71,47 @@ } ], "assigned_files": [ + "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", "src/friendli/container/completions.py", "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", + "src/friendli/serverless/completions.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/completions.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/file.py", "src/friendli_core/container.py", - "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/image.py", + "src/friendli_core/endpoint.py", + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/model.py", "src/friendli_core/toolassistedchat.py", - "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", + "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", - "src/friendli_core/audio.py" + "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/audio.y" ], "can_expand": true }, @@ -109,7 +129,6 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", - "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -343,25 +362,8 @@ } ], "assigned_files": [ - "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", - "src/friendli_core/friendlicore_serverless_chat.py", - "src/friendli_core/dedicated.py", - "src/friendli_core/friendlicore_serverless_token.py", - "src/friendli_core/serverless.py", - "src/friendli_core/friendlicore_serverless_completions.py" + "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py" ], "can_expand": true }, @@ -390,7 +392,6 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", - "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -413,6 +414,13 @@ ], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 1826475..17181a1 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "b64fffca672b341c4af1d01e732cc3da79147f28", + "commit_hash": "47865282250c727f1bd2ee10aa2a6a9d8a48037d", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 6fad7a9..c9a8366 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -8,6 +8,7 @@ graph LR Hooks_Extensibility["Hooks & Extensibility"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -96,6 +97,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 535270d..61e95c3 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -117,3 +117,12 @@ _Last updated: 2025-09-13 20:27:42 UTC_ - [overview.md](./overview.md) _Last updated: 2025-09-20 20:28:14 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-09-27 20:30:20 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 6fad7a9..c9a8366 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -8,6 +8,7 @@ graph LR Hooks_Extensibility["Hooks & Extensibility"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -96,6 +97,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 1a2179a55e80df9c007c0f36418bac72f3a356a5 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 4 Oct 2025 20:31:16 +0000 Subject: [PATCH 14/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 73 ++++++++++++++----------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++ docs/architecture/on_boarding.md | 9 +++ docs/architecture/overview.md | 7 +++ 5 files changed, 64 insertions(+), 34 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index d63c497..30a8373 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -13,11 +13,9 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/sdk.py", "src/friendli/friendli.py", "src/friendli/__init__.py", - "src/friendli/config.py", - "src/friendli_core/sdkconfiguration.py" + "src/friendli_core/sdk.py" ], "can_expand": true }, @@ -33,11 +31,13 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", "src/friendli/httpclient.py", + "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/_version.py", - "src/friendli_core/httpclient.py" + "src/friendli_core/endpoint.py", + "src/friendli_core/basesdk.py", + "src/friendli_core/httpclient.py", + "src/friendli_core/sdkconfiguration.py" ], "can_expand": true }, @@ -71,47 +71,27 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", "src/friendli/container/completions.py", "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", - "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli_core/completions.py", "src/friendli_core/file.py", - "src/friendli_core/container.py", + "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/friendlicore_serverless_token.py", - "src/friendli_core/model.py", + "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", + "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", - "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", - "/home/ubuntu/CodeBoarding/repo/friendli-python/src/friendli_core/audio.y" + "src/friendli_core/audio.py" ], "can_expand": true }, @@ -129,6 +109,7 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -362,8 +343,26 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py" + "src/friendli/serverless/completions.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", + "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli_core/dedicated.py", + "src/friendli_core/container.py", + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/serverless.py", + "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true }, @@ -392,6 +391,7 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", + "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -421,6 +421,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 17181a1..a51d3f8 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "47865282250c727f1bd2ee10aa2a6a9d8a48037d", + "commit_hash": "071467ad6d4b26f39ca742a606531b75ec6ab2b7", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index c9a8366..22f83f9 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -9,6 +9,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -103,6 +104,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 61e95c3..7f963c1 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -126,3 +126,12 @@ _Last updated: 2025-09-20 20:28:14 UTC_ - [overview.md](./overview.md) _Last updated: 2025-09-27 20:30:20 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-10-04 20:31:16 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index c9a8366..22f83f9 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -9,6 +9,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -103,6 +104,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 70742a3b1833b0e1a9613a77c30e18be5e13e7f5 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 11 Oct 2025 20:28:27 +0000 Subject: [PATCH 15/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 47 ++++++++++++++----------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 ++++ docs/architecture/on_boarding.md | 9 +++++ docs/architecture/overview.md | 7 ++++ 5 files changed, 51 insertions(+), 21 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 30a8373..8dd62d5 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -34,7 +34,7 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/endpoint.py", + "src/friendli_core/_version.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -75,20 +75,36 @@ "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", + "src/friendli/serverless/completions.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", + "src/friendli_core/container.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", + "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", + "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -109,7 +125,6 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", - "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -317,7 +332,7 @@ "src/friendli_core/models/dedicateddetokenizationsuccess.py", "src/friendli_core/models/create_datasetop.py", "src/friendli_core/models/init_uploadop.py", - "src/friendli_core/models/streamedchatdata.py", + "src/friendli_core/models/streamedchatchoice.py", "src/friendli_core/models/fileinfo.py", "src/friendli_core/models/streamedcompletiondata.py", "src/friendli_core/types/__init__.py", @@ -343,26 +358,12 @@ } ], "assigned_files": [ - "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/chat.py", "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", - "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/dedicated.py", - "src/friendli_core/container.py", - "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/endpoint.py", "src/friendli_core/serverless.py", - "src/friendli_core/friendlicore_serverless_completions.py" + "src/friendli_core/model.py" ], "can_expand": true }, @@ -391,7 +392,6 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", - "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -428,6 +428,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index a51d3f8..0a058e4 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "071467ad6d4b26f39ca742a606531b75ec6ab2b7", + "commit_hash": "1a2179a55e80df9c007c0f36418bac72f3a356a5", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 22f83f9..b4f2f6c 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -10,6 +10,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -110,6 +111,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 7f963c1..a559723 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -135,3 +135,12 @@ _Last updated: 2025-09-27 20:30:20 UTC_ - [overview.md](./overview.md) _Last updated: 2025-10-04 20:31:16 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-10-11 20:28:27 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 22f83f9..b4f2f6c 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -10,6 +10,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -110,6 +111,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From d7d7bffb1c9170a4f834e6fb459a72ec7dc5a1d3 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 18 Oct 2025 20:31:42 +0000 Subject: [PATCH 16/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 25 ++++++++++++++++--------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++++++ docs/architecture/on_boarding.md | 9 +++++++++ docs/architecture/overview.md | 7 +++++++ 5 files changed, 40 insertions(+), 10 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 8dd62d5..d9442f4 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -34,7 +34,6 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/_version.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -72,17 +71,14 @@ ], "assigned_files": [ "src/friendli/container/completions.py", - "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", "src/friendli/serverless/chat.py", "src/friendli/serverless/tool_assisted_chat.py", "src/friendli/serverless/token.py", "src/friendli/serverless/knowledge.py", "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/chat.py", "src/friendli/dedicated/image.py", "src/friendli/dedicated/token.py", @@ -94,7 +90,6 @@ "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", - "src/friendli_core/container.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", @@ -125,6 +120,8 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli/serverless/model.py", + "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -332,7 +329,7 @@ "src/friendli_core/models/dedicateddetokenizationsuccess.py", "src/friendli_core/models/create_datasetop.py", "src/friendli_core/models/init_uploadop.py", - "src/friendli_core/models/streamedchatchoice.py", + "src/friendli_core/models/streamedchatdata.py", "src/friendli_core/models/fileinfo.py", "src/friendli_core/models/streamedcompletiondata.py", "src/friendli_core/types/__init__.py", @@ -358,12 +355,14 @@ } ], "assigned_files": [ - "src/friendli/serverless/model.py", + "src/friendli/container/__init__.py", + "src/friendli/serverless/__init__.py", + "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/endpoint.py", "src/friendli_core/dedicated.py", + "src/friendli_core/container.py", "src/friendli_core/endpoint.py", - "src/friendli_core/serverless.py", - "src/friendli_core/model.py" + "src/friendli_core/serverless.py" ], "can_expand": true }, @@ -392,6 +391,7 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", + "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -435,6 +435,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 0a058e4..4491952 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "1a2179a55e80df9c007c0f36418bac72f3a356a5", + "commit_hash": "70742a3b1833b0e1a9613a77c30e18be5e13e7f5", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index b4f2f6c..bd64bf2 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -11,6 +11,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -117,6 +118,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index a559723..dda0b7d 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -144,3 +144,12 @@ _Last updated: 2025-10-04 20:31:16 UTC_ - [overview.md](./overview.md) _Last updated: 2025-10-11 20:28:27 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-10-18 20:31:42 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index b4f2f6c..bd64bf2 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -11,6 +11,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -117,6 +118,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 5f170958411e5d2334a02b79ff5033b41b4ae9e1 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 25 Oct 2025 20:31:31 +0000 Subject: [PATCH 17/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 17 ++++++++++++----- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++++++ docs/architecture/on_boarding.md | 9 +++++++++ docs/architecture/overview.md | 7 +++++++ 5 files changed, 36 insertions(+), 6 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index d9442f4..86e14e1 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -15,6 +15,7 @@ "assigned_files": [ "src/friendli/friendli.py", "src/friendli/__init__.py", + "src/friendli/config.py", "src/friendli_core/sdk.py" ], "can_expand": true @@ -32,7 +33,6 @@ ], "assigned_files": [ "src/friendli/httpclient.py", - "src/friendli/config.py", "src/friendli_core/__init__.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", @@ -76,10 +76,12 @@ "src/friendli/serverless/completions.py", "src/friendli/serverless/chat.py", "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", "src/friendli/serverless/token.py", "src/friendli/serverless/knowledge.py", "src/friendli/dedicated/completions.py", "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", "src/friendli/dedicated/image.py", "src/friendli/dedicated/token.py", "src/friendli/dedicated/audio.py", @@ -93,8 +95,10 @@ "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", + "src/friendli_core/endpoint.py", "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", + "src/friendli_core/model.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", @@ -120,8 +124,6 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", - "src/friendli/serverless/model.py", - "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -358,10 +360,8 @@ "src/friendli/container/__init__.py", "src/friendli/serverless/__init__.py", "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/endpoint.py", "src/friendli_core/dedicated.py", "src/friendli_core/container.py", - "src/friendli_core/endpoint.py", "src/friendli_core/serverless.py" ], "can_expand": true @@ -442,6 +442,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 4491952..8f807a2 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "70742a3b1833b0e1a9613a77c30e18be5e13e7f5", + "commit_hash": "d7d7bffb1c9170a4f834e6fb459a72ec7dc5a1d3", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index bd64bf2..761f945 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -12,6 +12,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -124,6 +125,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index dda0b7d..c2b643e 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -153,3 +153,12 @@ _Last updated: 2025-10-11 20:28:27 UTC_ - [overview.md](./overview.md) _Last updated: 2025-10-18 20:31:42 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-10-25 20:31:31 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index bd64bf2..761f945 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -12,6 +12,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -124,6 +125,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From c098d4cf4fef2de945984f3f69232dbbfa5b882e Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 8 Nov 2025 20:30:16 +0000 Subject: [PATCH 18/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 6 - JSON files created/updated: 7 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Data_Models_Error_Handling.md | 2 +- .codeboarding/Hooks_Extensibility.json | 81 ------------------- .codeboarding/Hooks_Extensibility.md | 50 ------------ .codeboarding/analysis.json | 51 +++++++----- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 ++- .../Data_Models_Error_Handling.md | 2 +- docs/architecture/on_boarding.md | 8 ++ docs/architecture/overview.md | 10 ++- 9 files changed, 56 insertions(+), 160 deletions(-) delete mode 100644 .codeboarding/Hooks_Extensibility.json delete mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Data_Models_Error_Handling.md b/.codeboarding/Data_Models_Error_Handling.md index 44e7898..304d639 100644 --- a/.codeboarding/Data_Models_Error_Handling.md +++ b/.codeboarding/Data_Models_Error_Handling.md @@ -70,7 +70,7 @@ Comprises practical code examples demonstrating how to effectively use the SDK's **Related Classes/Methods**: - `examples` -- `docs` +- `docs` diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json deleted file mode 100644 index 9e00910..0000000 --- a/.codeboarding/Hooks_Extensibility.json +++ /dev/null @@ -1,81 +0,0 @@ -{ - "description": "Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization.", - "components": [ - { - "name": "Hook Contexts (DTOs)", - "description": "A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass relevant data and state through different stages of the API request/response lifecycle. These contexts provide the necessary information for hooks to operate on.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.types.HookContext", - "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", - "reference_start_line": 11, - "reference_end_line": 30 - }, - { - "qualified_name": "friendli_core._hooks.types.BeforeRequestContext", - "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", - "reference_start_line": 33, - "reference_end_line": 41 - }, - { - "qualified_name": "friendli_core._hooks.types.AfterSuccessContext", - "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", - "reference_start_line": 44, - "reference_end_line": 52 - }, - { - "qualified_name": "friendli_core._hooks.types.AfterErrorContext", - "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", - "reference_start_line": 55, - "reference_end_line": 63 - } - ] - }, - { - "name": "Hook Interface", - "description": "Defines the abstract interface or base class that custom hooks must implement. It establishes the contract for various hook methods (e.g., `before_request`, `after_success`, `after_error`), ensuring a consistent extensibility point for SDK users.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.types.Hooks", - "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/types.py", - "reference_start_line": 99, - "reference_end_line": 114 - } - ] - }, - { - "name": "SDK Hooks Orchestrator", - "description": "The central manager responsible for registering, storing, and orchestrating the execution of various custom hooks at the appropriate stages of the SDK's request/response lifecycle. It acts as a facade for the entire hooks mechanism.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.sdkhooks.SDKHooks", - "reference_file": "/mnt/e/StartUp/friendli-python/src/friendli_core/_hooks/sdkhooks.py", - "reference_start_line": 21, - "reference_end_line": 78 - } - ] - } - ], - "components_relations": [ - { - "relation": "provides data to", - "src_name": "Hook Contexts (DTOs)", - "dst_name": "Hook Interface" - }, - { - "relation": "interacts with", - "src_name": "SDK Hooks Orchestrator", - "dst_name": "Hook Contexts (DTOs)" - }, - { - "relation": "orchestrates", - "src_name": "SDK Hooks Orchestrator", - "dst_name": "Hook Interface" - }, - { - "relation": "receives", - "src_name": "Hook Interface", - "dst_name": "Hook Contexts (DTOs)" - } - ] -} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md deleted file mode 100644 index 0264029..0000000 --- a/.codeboarding/Hooks_Extensibility.md +++ /dev/null @@ -1,50 +0,0 @@ -```mermaid -graph LR - Hook_Contexts_DTOs_["Hook Contexts (DTOs)"] - Hook_Interface["Hook Interface"] - SDK_Hooks_Orchestrator["SDK Hooks Orchestrator"] - Hook_Contexts_DTOs_ -- "provides data to" --> Hook_Interface - SDK_Hooks_Orchestrator -- "interacts with" --> Hook_Contexts_DTOs_ - SDK_Hooks_Orchestrator -- "orchestrates" --> Hook_Interface - Hook_Interface -- "receives" --> Hook_Contexts_DTOs_ -``` - -[![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) - -## Details - -Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. - -### Hook Contexts (DTOs) -A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass relevant data and state through different stages of the API request/response lifecycle. These contexts provide the necessary information for hooks to operate on. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.types.HookContext`:11-30 -- `friendli_core._hooks.types.BeforeRequestContext`:33-41 -- `friendli_core._hooks.types.AfterSuccessContext`:44-52 -- `friendli_core._hooks.types.AfterErrorContext`:55-63 - - -### Hook Interface -Defines the abstract interface or base class that custom hooks must implement. It establishes the contract for various hook methods (e.g., `before_request`, `after_success`, `after_error`), ensuring a consistent extensibility point for SDK users. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.types.Hooks`:99-114 - - -### SDK Hooks Orchestrator -The central manager responsible for registering, storing, and orchestrating the execution of various custom hooks at the appropriate stages of the SDK's request/response lifecycle. It acts as a facade for the entire hooks mechanism. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.sdkhooks.SDKHooks`:21-78 - - - - -### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 86e14e1..4029405 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -15,7 +15,6 @@ "assigned_files": [ "src/friendli/friendli.py", "src/friendli/__init__.py", - "src/friendli/config.py", "src/friendli_core/sdk.py" ], "can_expand": true @@ -33,7 +32,11 @@ ], "assigned_files": [ "src/friendli/httpclient.py", + "src/friendli/config.py", "src/friendli_core/__init__.py", + "src/friendli_core/container.py", + "src/friendli_core/endpoint.py", + "src/friendli_core/model.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -71,39 +74,23 @@ ], "assigned_files": [ "src/friendli/container/completions.py", + "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", - "src/friendli/serverless/completions.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", - "src/friendli_core/model.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", - "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -357,12 +344,25 @@ } ], "assigned_files": [ - "src/friendli/container/__init__.py", + "src/friendli/serverless/completions.py", "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/dedicated.py", - "src/friendli_core/container.py", - "src/friendli_core/serverless.py" + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/serverless.py", + "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true }, @@ -383,7 +383,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": true + "can_expand": false }, { "name": "Unclassified", @@ -449,6 +449,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 8f807a2..94416b2 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "d7d7bffb1c9170a4f834e6fb459a72ec7dc5a1d3", + "commit_hash": "5f170958411e5d2334a02b79ff5033b41b4ae9e1", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 761f945..df05919 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -13,6 +13,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -24,7 +25,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -82,7 +82,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -131,6 +131,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/Data_Models_Error_Handling.md b/docs/architecture/Data_Models_Error_Handling.md index 44e7898..304d639 100644 --- a/docs/architecture/Data_Models_Error_Handling.md +++ b/docs/architecture/Data_Models_Error_Handling.md @@ -70,7 +70,7 @@ Comprises practical code examples demonstrating how to effectively use the SDK's **Related Classes/Methods**: - `examples` -- `docs` +- `docs` diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index c2b643e..8b8ffab 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -162,3 +162,11 @@ _Last updated: 2025-10-18 20:31:42 UTC_ - [overview.md](./overview.md) _Last updated: 2025-10-25 20:31:31 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-11-08 20:30:16 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 761f945..df05919 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -13,6 +13,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -24,7 +25,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -82,7 +82,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -131,6 +131,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 60cff9cc1e4b5f31db88108b2281c75b49aa1555 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 15 Nov 2025 20:35:14 +0000 Subject: [PATCH 19/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 176 +++++++++++++++++++++++ .codeboarding/Hooks_Extensibility.md | 93 ++++++++++++ .codeboarding/analysis.json | 45 +++--- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 +- docs/architecture/Hooks_Extensibility.md | 83 ++++++++--- docs/architecture/on_boarding.md | 9 ++ docs/architecture/overview.md | 10 +- 8 files changed, 386 insertions(+), 42 deletions(-) create mode 100644 .codeboarding/Hooks_Extensibility.json create mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json new file mode 100644 index 0000000..09eb378 --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.json @@ -0,0 +1,176 @@ +{ + "description": "The `friendli_core._hooks` subsystem provides a robust extension mechanism for the Friendli SDK. The `FriendliClient` initiates this by providing custom logic to the `HookRegistrar`, which then configures the `SDKHookOrchestrator`. This orchestrator is central to the subsystem, managing and invoking various hook types—defined by `HookDefinitions`—at critical junctures. For instance, the `HttpClient` triggers hooks before sending requests and after receiving responses, while the `SDKErrorProcessor` activates specific hooks when exceptions occur. This design allows for flexible customization of SDK behavior without altering its core implementation, enhancing adaptability and maintainability.", + "components": [ + { + "name": "FriendliClient", + "description": "The primary interface for users to interact with the SDK and register custom extensions. Initializes the SDK and provides custom hook implementations to the `HookRegistrar`.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.FriendliClient", + "reference_file": "src/friendli_core/sdk.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "assigned_files": [], + "can_expand": true + }, + { + "name": "HookRegistrar", + "description": "The component responsible for receiving and organizing custom hook implementations. Receives custom hook instances from `FriendliClient` and adds them to the `SDKHookOrchestrator` for later invocation.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.registration.init_hooks", + "reference_file": "src/friendli_core/_hooks/registration.py", + "reference_start_line": 8, + "reference_end_line": 12 + } + ], + "assigned_files": [ + "src/friendli_core/_hooks/registration.py" + ], + "can_expand": true + }, + { + "name": "SDKHookOrchestrator", + "description": "The central component that manages the lifecycle of hooks, invoking them at appropriate stages of SDK operations. Stores and manages different types of hooks. It is responsible for invoking the correct hooks (e.g., `before_request`, `after_success`, `after_error`) when triggered by `HttpClient` or `SDKErrorProcessor`, ensuring they adhere to `HookDefinitions`.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.sdkhooks.SDKHooks", + "reference_file": "src/friendli_core/_hooks/sdkhooks.py", + "reference_start_line": 22, + "reference_end_line": 79 + } + ], + "assigned_files": [ + "src/friendli_core/_hooks/sdkhooks.py" + ], + "can_expand": true + }, + { + "name": "HookDefinitions", + "description": "The collection of abstract interfaces and data structures that define the contract and context for all types of hooks. Defines the abstract base classes for various hook types (e.g., `SDKInitHook`, `BeforeRequestHook`) and their associated context objects, establishing the API for custom extensions.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.types.Hooks", + "reference_file": "src/friendli_core/_hooks/types.py", + "reference_start_line": 100, + "reference_end_line": 115 + }, + { + "qualified_name": "friendli_core._hooks.types.SDKInitHook", + "reference_file": "src/friendli_core/_hooks/types.py", + "reference_start_line": 67, + "reference_end_line": 70 + }, + { + "qualified_name": "friendli_core._hooks.types.BeforeRequestHook", + "reference_file": "src/friendli_core/_hooks/types.py", + "reference_start_line": 73, + "reference_end_line": 78 + }, + { + "qualified_name": "friendli_core._hooks.types.AfterSuccessHook", + "reference_file": "src/friendli_core/_hooks/types.py", + "reference_start_line": 81, + "reference_end_line": 86 + }, + { + "qualified_name": "friendli_core._hooks.types.AfterErrorHook", + "reference_file": "src/friendli_core/_hooks/types.py", + "reference_start_line": 89, + "reference_end_line": 97 + }, + { + "qualified_name": "friendli_core._hooks.types.HookContext", + "reference_file": "src/friendli_core/_hooks/types.py", + "reference_start_line": 12, + "reference_end_line": 31 + } + ], + "assigned_files": [ + "src/friendli_core/_hooks/types.py" + ], + "can_expand": false + }, + { + "name": "HttpClient", + "description": "The underlying mechanism for making external network requests, which integrates with the hook system. Executes network requests. Before sending a request, it notifies the `SDKHookOrchestrator` to run `before_request` hooks. After receiving a response, it notifies the `SDKHookOrchestrator` to run `after_success` hooks.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.httpclient.HttpClient", + "reference_file": "src/friendli_core/httpclient.py", + "reference_start_line": 11, + "reference_end_line": 47 + } + ], + "assigned_files": [], + "can_expand": false + }, + { + "name": "SDKErrorProcessor", + "description": "The part of the SDK responsible for handling exceptions and triggering error-specific hooks. Catches and processes exceptions during SDK operations. Upon an error, it notifies the `SDKHookOrchestrator` to run `after_error` hooks.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core.SDKErrorProcessor", + "reference_file": "src/friendli_core/models/sdkerror.py", + "reference_start_line": 12, + "reference_end_line": 39 + } + ], + "assigned_files": [], + "can_expand": true + }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [ + "src/friendli_core/_hooks/__init__.py" + ], + "can_expand": false + } + ], + "components_relations": [ + { + "relation": "implements", + "src_name": "SDKHookOrchestrator", + "dst_name": "HookDefinitions" + }, + { + "relation": "configures", + "src_name": "HookRegistrar", + "dst_name": "SDKHookOrchestrator" + }, + { + "relation": "uses", + "src_name": "SDKHookOrchestrator", + "dst_name": "HookDefinitions" + }, + { + "relation": "registers hooks with", + "src_name": "FriendliClient", + "dst_name": "HookRegistrar" + }, + { + "relation": "registers hooks with", + "src_name": "HookRegistrar", + "dst_name": "SDKHookOrchestrator" + }, + { + "relation": "invokes before_request hooks on", + "src_name": "HttpClient", + "dst_name": "SDKHookOrchestrator" + }, + { + "relation": "invokes after_success hooks on", + "src_name": "HttpClient", + "dst_name": "SDKHookOrchestrator" + }, + { + "relation": "invokes after_error hooks on", + "src_name": "SDKErrorProcessor", + "dst_name": "SDKHookOrchestrator" + } + ] +} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md new file mode 100644 index 0000000..9a68b91 --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.md @@ -0,0 +1,93 @@ +```mermaid +graph LR + FriendliClient["FriendliClient"] + HookRegistrar["HookRegistrar"] + SDKHookOrchestrator["SDKHookOrchestrator"] + HookDefinitions["HookDefinitions"] + HttpClient["HttpClient"] + SDKErrorProcessor["SDKErrorProcessor"] + Unclassified["Unclassified"] + SDKHookOrchestrator -- "implements" --> HookDefinitions + HookRegistrar -- "configures" --> SDKHookOrchestrator + SDKHookOrchestrator -- "uses" --> HookDefinitions + FriendliClient -- "registers hooks with" --> HookRegistrar + HookRegistrar -- "registers hooks with" --> SDKHookOrchestrator + HttpClient -- "invokes before_request hooks on" --> SDKHookOrchestrator + HttpClient -- "invokes after_success hooks on" --> SDKHookOrchestrator + SDKErrorProcessor -- "invokes after_error hooks on" --> SDKHookOrchestrator +``` + +[![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) + +## Details + +The `friendli_core._hooks` subsystem provides a robust extension mechanism for the Friendli SDK. The `FriendliClient` initiates this by providing custom logic to the `HookRegistrar`, which then configures the `SDKHookOrchestrator`. This orchestrator is central to the subsystem, managing and invoking various hook types—defined by `HookDefinitions`—at critical junctures. For instance, the `HttpClient` triggers hooks before sending requests and after receiving responses, while the `SDKErrorProcessor` activates specific hooks when exceptions occur. This design allows for flexible customization of SDK behavior without altering its core implementation, enhancing adaptability and maintainability. + +### FriendliClient +The primary interface for users to interact with the SDK and register custom extensions. Initializes the SDK and provides custom hook implementations to the `HookRegistrar`. + + +**Related Classes/Methods**: + +- `friendli_core.FriendliClient` + + +### HookRegistrar +The component responsible for receiving and organizing custom hook implementations. Receives custom hook instances from `FriendliClient` and adds them to the `SDKHookOrchestrator` for later invocation. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.registration.init_hooks`:8-12 + + +### SDKHookOrchestrator +The central component that manages the lifecycle of hooks, invoking them at appropriate stages of SDK operations. Stores and manages different types of hooks. It is responsible for invoking the correct hooks (e.g., `before_request`, `after_success`, `after_error`) when triggered by `HttpClient` or `SDKErrorProcessor`, ensuring they adhere to `HookDefinitions`. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 + + +### HookDefinitions +The collection of abstract interfaces and data structures that define the contract and context for all types of hooks. Defines the abstract base classes for various hook types (e.g., `SDKInitHook`, `BeforeRequestHook`) and their associated context objects, establishing the API for custom extensions. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.Hooks`:100-115 +- `friendli_core._hooks.types.SDKInitHook`:67-70 +- `friendli_core._hooks.types.BeforeRequestHook`:73-78 +- `friendli_core._hooks.types.AfterSuccessHook`:81-86 +- `friendli_core._hooks.types.AfterErrorHook`:89-97 +- `friendli_core._hooks.types.HookContext`:12-31 + + +### HttpClient +The underlying mechanism for making external network requests, which integrates with the hook system. Executes network requests. Before sending a request, it notifies the `SDKHookOrchestrator` to run `before_request` hooks. After receiving a response, it notifies the `SDKHookOrchestrator` to run `after_success` hooks. + + +**Related Classes/Methods**: + +- `friendli_core.httpclient.HttpClient`:11-47 + + +### SDKErrorProcessor +The part of the SDK responsible for handling exceptions and triggering error-specific hooks. Catches and processes exceptions during SDK operations. Upon an error, it notifies the `SDKHookOrchestrator` to run `after_error` hooks. + + +**Related Classes/Methods**: + +- `friendli_core.SDKErrorProcessor`:12-39 + + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + +**Related Classes/Methods**: _None_ + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 4029405..8106be7 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -14,8 +14,7 @@ ], "assigned_files": [ "src/friendli/friendli.py", - "src/friendli/__init__.py", - "src/friendli_core/sdk.py" + "src/friendli/__init__.py" ], "can_expand": true }, @@ -34,9 +33,8 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/container.py", + "src/friendli_core/sdk.py", "src/friendli_core/endpoint.py", - "src/friendli_core/model.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -77,6 +75,20 @@ "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", + "src/friendli/serverless/completions.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", @@ -111,6 +123,7 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -344,22 +357,9 @@ } ], "assigned_files": [ - "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/dedicated.py", + "src/friendli_core/container.py", "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/serverless.py", "src/friendli_core/friendlicore_serverless_completions.py" @@ -383,7 +383,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": false + "can_expand": true }, { "name": "Unclassified", @@ -456,6 +456,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 94416b2..1917a2b 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "5f170958411e5d2334a02b79ff5033b41b4ae9e1", + "commit_hash": "c098d4cf4fef2de945984f3f69232dbbfa5b882e", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index df05919..626cd13 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -14,6 +14,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -25,6 +26,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -82,7 +84,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -137,6 +139,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/Hooks_Extensibility.md b/docs/architecture/Hooks_Extensibility.md index 0264029..9a68b91 100644 --- a/docs/architecture/Hooks_Extensibility.md +++ b/docs/architecture/Hooks_Extensibility.md @@ -1,50 +1,93 @@ ```mermaid graph LR - Hook_Contexts_DTOs_["Hook Contexts (DTOs)"] - Hook_Interface["Hook Interface"] - SDK_Hooks_Orchestrator["SDK Hooks Orchestrator"] - Hook_Contexts_DTOs_ -- "provides data to" --> Hook_Interface - SDK_Hooks_Orchestrator -- "interacts with" --> Hook_Contexts_DTOs_ - SDK_Hooks_Orchestrator -- "orchestrates" --> Hook_Interface - Hook_Interface -- "receives" --> Hook_Contexts_DTOs_ + FriendliClient["FriendliClient"] + HookRegistrar["HookRegistrar"] + SDKHookOrchestrator["SDKHookOrchestrator"] + HookDefinitions["HookDefinitions"] + HttpClient["HttpClient"] + SDKErrorProcessor["SDKErrorProcessor"] + Unclassified["Unclassified"] + SDKHookOrchestrator -- "implements" --> HookDefinitions + HookRegistrar -- "configures" --> SDKHookOrchestrator + SDKHookOrchestrator -- "uses" --> HookDefinitions + FriendliClient -- "registers hooks with" --> HookRegistrar + HookRegistrar -- "registers hooks with" --> SDKHookOrchestrator + HttpClient -- "invokes before_request hooks on" --> SDKHookOrchestrator + HttpClient -- "invokes after_success hooks on" --> SDKHookOrchestrator + SDKErrorProcessor -- "invokes after_error hooks on" --> SDKHookOrchestrator ``` [![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) ## Details -Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. +The `friendli_core._hooks` subsystem provides a robust extension mechanism for the Friendli SDK. The `FriendliClient` initiates this by providing custom logic to the `HookRegistrar`, which then configures the `SDKHookOrchestrator`. This orchestrator is central to the subsystem, managing and invoking various hook types—defined by `HookDefinitions`—at critical junctures. For instance, the `HttpClient` triggers hooks before sending requests and after receiving responses, while the `SDKErrorProcessor` activates specific hooks when exceptions occur. This design allows for flexible customization of SDK behavior without altering its core implementation, enhancing adaptability and maintainability. -### Hook Contexts (DTOs) -A set of specialized Data Transfer Objects (DTOs) that encapsulate and pass relevant data and state through different stages of the API request/response lifecycle. These contexts provide the necessary information for hooks to operate on. +### FriendliClient +The primary interface for users to interact with the SDK and register custom extensions. Initializes the SDK and provides custom hook implementations to the `HookRegistrar`. **Related Classes/Methods**: -- `friendli_core._hooks.types.HookContext`:11-30 -- `friendli_core._hooks.types.BeforeRequestContext`:33-41 -- `friendli_core._hooks.types.AfterSuccessContext`:44-52 -- `friendli_core._hooks.types.AfterErrorContext`:55-63 +- `friendli_core.FriendliClient` -### Hook Interface -Defines the abstract interface or base class that custom hooks must implement. It establishes the contract for various hook methods (e.g., `before_request`, `after_success`, `after_error`), ensuring a consistent extensibility point for SDK users. +### HookRegistrar +The component responsible for receiving and organizing custom hook implementations. Receives custom hook instances from `FriendliClient` and adds them to the `SDKHookOrchestrator` for later invocation. **Related Classes/Methods**: -- `friendli_core._hooks.types.Hooks`:99-114 +- `friendli_core._hooks.registration.init_hooks`:8-12 -### SDK Hooks Orchestrator -The central manager responsible for registering, storing, and orchestrating the execution of various custom hooks at the appropriate stages of the SDK's request/response lifecycle. It acts as a facade for the entire hooks mechanism. +### SDKHookOrchestrator +The central component that manages the lifecycle of hooks, invoking them at appropriate stages of SDK operations. Stores and manages different types of hooks. It is responsible for invoking the correct hooks (e.g., `before_request`, `after_success`, `after_error`) when triggered by `HttpClient` or `SDKErrorProcessor`, ensuring they adhere to `HookDefinitions`. **Related Classes/Methods**: -- `friendli_core._hooks.sdkhooks.SDKHooks`:21-78 +- `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 +### HookDefinitions +The collection of abstract interfaces and data structures that define the contract and context for all types of hooks. Defines the abstract base classes for various hook types (e.g., `SDKInitHook`, `BeforeRequestHook`) and their associated context objects, establishing the API for custom extensions. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.types.Hooks`:100-115 +- `friendli_core._hooks.types.SDKInitHook`:67-70 +- `friendli_core._hooks.types.BeforeRequestHook`:73-78 +- `friendli_core._hooks.types.AfterSuccessHook`:81-86 +- `friendli_core._hooks.types.AfterErrorHook`:89-97 +- `friendli_core._hooks.types.HookContext`:12-31 + + +### HttpClient +The underlying mechanism for making external network requests, which integrates with the hook system. Executes network requests. Before sending a request, it notifies the `SDKHookOrchestrator` to run `before_request` hooks. After receiving a response, it notifies the `SDKHookOrchestrator` to run `after_success` hooks. + + +**Related Classes/Methods**: + +- `friendli_core.httpclient.HttpClient`:11-47 + + +### SDKErrorProcessor +The part of the SDK responsible for handling exceptions and triggering error-specific hooks. Catches and processes exceptions during SDK operations. Upon an error, it notifies the `SDKHookOrchestrator` to run `after_error` hooks. + + +**Related Classes/Methods**: + +- `friendli_core.SDKErrorProcessor`:12-39 + + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + +**Related Classes/Methods**: _None_ + ### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 8b8ffab..73168bd 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -170,3 +170,12 @@ _Last updated: 2025-10-25 20:31:31 UTC_ - [overview.md](./overview.md) _Last updated: 2025-11-08 20:30:16 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-11-15 20:35:14 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index df05919..626cd13 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -14,6 +14,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -25,6 +26,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -82,7 +84,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -137,6 +139,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 2fdc7274073734394c843c58e6c409cd8b275630 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 22 Nov 2025 20:33:01 +0000 Subject: [PATCH 20/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 6 - JSON files created/updated: 7 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 176 ------------------------ .codeboarding/Hooks_Extensibility.md | 93 ------------- .codeboarding/analysis.json | 35 +++-- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 +- docs/architecture/on_boarding.md | 8 ++ docs/architecture/overview.md | 10 +- 7 files changed, 46 insertions(+), 288 deletions(-) delete mode 100644 .codeboarding/Hooks_Extensibility.json delete mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json deleted file mode 100644 index 09eb378..0000000 --- a/.codeboarding/Hooks_Extensibility.json +++ /dev/null @@ -1,176 +0,0 @@ -{ - "description": "The `friendli_core._hooks` subsystem provides a robust extension mechanism for the Friendli SDK. The `FriendliClient` initiates this by providing custom logic to the `HookRegistrar`, which then configures the `SDKHookOrchestrator`. This orchestrator is central to the subsystem, managing and invoking various hook types—defined by `HookDefinitions`—at critical junctures. For instance, the `HttpClient` triggers hooks before sending requests and after receiving responses, while the `SDKErrorProcessor` activates specific hooks when exceptions occur. This design allows for flexible customization of SDK behavior without altering its core implementation, enhancing adaptability and maintainability.", - "components": [ - { - "name": "FriendliClient", - "description": "The primary interface for users to interact with the SDK and register custom extensions. Initializes the SDK and provides custom hook implementations to the `HookRegistrar`.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core.FriendliClient", - "reference_file": "src/friendli_core/sdk.py", - "reference_start_line": null, - "reference_end_line": null - } - ], - "assigned_files": [], - "can_expand": true - }, - { - "name": "HookRegistrar", - "description": "The component responsible for receiving and organizing custom hook implementations. Receives custom hook instances from `FriendliClient` and adds them to the `SDKHookOrchestrator` for later invocation.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.registration.init_hooks", - "reference_file": "src/friendli_core/_hooks/registration.py", - "reference_start_line": 8, - "reference_end_line": 12 - } - ], - "assigned_files": [ - "src/friendli_core/_hooks/registration.py" - ], - "can_expand": true - }, - { - "name": "SDKHookOrchestrator", - "description": "The central component that manages the lifecycle of hooks, invoking them at appropriate stages of SDK operations. Stores and manages different types of hooks. It is responsible for invoking the correct hooks (e.g., `before_request`, `after_success`, `after_error`) when triggered by `HttpClient` or `SDKErrorProcessor`, ensuring they adhere to `HookDefinitions`.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.sdkhooks.SDKHooks", - "reference_file": "src/friendli_core/_hooks/sdkhooks.py", - "reference_start_line": 22, - "reference_end_line": 79 - } - ], - "assigned_files": [ - "src/friendli_core/_hooks/sdkhooks.py" - ], - "can_expand": true - }, - { - "name": "HookDefinitions", - "description": "The collection of abstract interfaces and data structures that define the contract and context for all types of hooks. Defines the abstract base classes for various hook types (e.g., `SDKInitHook`, `BeforeRequestHook`) and their associated context objects, establishing the API for custom extensions.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.types.Hooks", - "reference_file": "src/friendli_core/_hooks/types.py", - "reference_start_line": 100, - "reference_end_line": 115 - }, - { - "qualified_name": "friendli_core._hooks.types.SDKInitHook", - "reference_file": "src/friendli_core/_hooks/types.py", - "reference_start_line": 67, - "reference_end_line": 70 - }, - { - "qualified_name": "friendli_core._hooks.types.BeforeRequestHook", - "reference_file": "src/friendli_core/_hooks/types.py", - "reference_start_line": 73, - "reference_end_line": 78 - }, - { - "qualified_name": "friendli_core._hooks.types.AfterSuccessHook", - "reference_file": "src/friendli_core/_hooks/types.py", - "reference_start_line": 81, - "reference_end_line": 86 - }, - { - "qualified_name": "friendli_core._hooks.types.AfterErrorHook", - "reference_file": "src/friendli_core/_hooks/types.py", - "reference_start_line": 89, - "reference_end_line": 97 - }, - { - "qualified_name": "friendli_core._hooks.types.HookContext", - "reference_file": "src/friendli_core/_hooks/types.py", - "reference_start_line": 12, - "reference_end_line": 31 - } - ], - "assigned_files": [ - "src/friendli_core/_hooks/types.py" - ], - "can_expand": false - }, - { - "name": "HttpClient", - "description": "The underlying mechanism for making external network requests, which integrates with the hook system. Executes network requests. Before sending a request, it notifies the `SDKHookOrchestrator` to run `before_request` hooks. After receiving a response, it notifies the `SDKHookOrchestrator` to run `after_success` hooks.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core.httpclient.HttpClient", - "reference_file": "src/friendli_core/httpclient.py", - "reference_start_line": 11, - "reference_end_line": 47 - } - ], - "assigned_files": [], - "can_expand": false - }, - { - "name": "SDKErrorProcessor", - "description": "The part of the SDK responsible for handling exceptions and triggering error-specific hooks. Catches and processes exceptions during SDK operations. Upon an error, it notifies the `SDKHookOrchestrator` to run `after_error` hooks.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core.SDKErrorProcessor", - "reference_file": "src/friendli_core/models/sdkerror.py", - "reference_start_line": 12, - "reference_end_line": 39 - } - ], - "assigned_files": [], - "can_expand": true - }, - { - "name": "Unclassified", - "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", - "referenced_source_code": [], - "assigned_files": [ - "src/friendli_core/_hooks/__init__.py" - ], - "can_expand": false - } - ], - "components_relations": [ - { - "relation": "implements", - "src_name": "SDKHookOrchestrator", - "dst_name": "HookDefinitions" - }, - { - "relation": "configures", - "src_name": "HookRegistrar", - "dst_name": "SDKHookOrchestrator" - }, - { - "relation": "uses", - "src_name": "SDKHookOrchestrator", - "dst_name": "HookDefinitions" - }, - { - "relation": "registers hooks with", - "src_name": "FriendliClient", - "dst_name": "HookRegistrar" - }, - { - "relation": "registers hooks with", - "src_name": "HookRegistrar", - "dst_name": "SDKHookOrchestrator" - }, - { - "relation": "invokes before_request hooks on", - "src_name": "HttpClient", - "dst_name": "SDKHookOrchestrator" - }, - { - "relation": "invokes after_success hooks on", - "src_name": "HttpClient", - "dst_name": "SDKHookOrchestrator" - }, - { - "relation": "invokes after_error hooks on", - "src_name": "SDKErrorProcessor", - "dst_name": "SDKHookOrchestrator" - } - ] -} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md deleted file mode 100644 index 9a68b91..0000000 --- a/.codeboarding/Hooks_Extensibility.md +++ /dev/null @@ -1,93 +0,0 @@ -```mermaid -graph LR - FriendliClient["FriendliClient"] - HookRegistrar["HookRegistrar"] - SDKHookOrchestrator["SDKHookOrchestrator"] - HookDefinitions["HookDefinitions"] - HttpClient["HttpClient"] - SDKErrorProcessor["SDKErrorProcessor"] - Unclassified["Unclassified"] - SDKHookOrchestrator -- "implements" --> HookDefinitions - HookRegistrar -- "configures" --> SDKHookOrchestrator - SDKHookOrchestrator -- "uses" --> HookDefinitions - FriendliClient -- "registers hooks with" --> HookRegistrar - HookRegistrar -- "registers hooks with" --> SDKHookOrchestrator - HttpClient -- "invokes before_request hooks on" --> SDKHookOrchestrator - HttpClient -- "invokes after_success hooks on" --> SDKHookOrchestrator - SDKErrorProcessor -- "invokes after_error hooks on" --> SDKHookOrchestrator -``` - -[![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) - -## Details - -The `friendli_core._hooks` subsystem provides a robust extension mechanism for the Friendli SDK. The `FriendliClient` initiates this by providing custom logic to the `HookRegistrar`, which then configures the `SDKHookOrchestrator`. This orchestrator is central to the subsystem, managing and invoking various hook types—defined by `HookDefinitions`—at critical junctures. For instance, the `HttpClient` triggers hooks before sending requests and after receiving responses, while the `SDKErrorProcessor` activates specific hooks when exceptions occur. This design allows for flexible customization of SDK behavior without altering its core implementation, enhancing adaptability and maintainability. - -### FriendliClient -The primary interface for users to interact with the SDK and register custom extensions. Initializes the SDK and provides custom hook implementations to the `HookRegistrar`. - - -**Related Classes/Methods**: - -- `friendli_core.FriendliClient` - - -### HookRegistrar -The component responsible for receiving and organizing custom hook implementations. Receives custom hook instances from `FriendliClient` and adds them to the `SDKHookOrchestrator` for later invocation. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.registration.init_hooks`:8-12 - - -### SDKHookOrchestrator -The central component that manages the lifecycle of hooks, invoking them at appropriate stages of SDK operations. Stores and manages different types of hooks. It is responsible for invoking the correct hooks (e.g., `before_request`, `after_success`, `after_error`) when triggered by `HttpClient` or `SDKErrorProcessor`, ensuring they adhere to `HookDefinitions`. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 - - -### HookDefinitions -The collection of abstract interfaces and data structures that define the contract and context for all types of hooks. Defines the abstract base classes for various hook types (e.g., `SDKInitHook`, `BeforeRequestHook`) and their associated context objects, establishing the API for custom extensions. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.types.Hooks`:100-115 -- `friendli_core._hooks.types.SDKInitHook`:67-70 -- `friendli_core._hooks.types.BeforeRequestHook`:73-78 -- `friendli_core._hooks.types.AfterSuccessHook`:81-86 -- `friendli_core._hooks.types.AfterErrorHook`:89-97 -- `friendli_core._hooks.types.HookContext`:12-31 - - -### HttpClient -The underlying mechanism for making external network requests, which integrates with the hook system. Executes network requests. Before sending a request, it notifies the `SDKHookOrchestrator` to run `before_request` hooks. After receiving a response, it notifies the `SDKHookOrchestrator` to run `after_success` hooks. - - -**Related Classes/Methods**: - -- `friendli_core.httpclient.HttpClient`:11-47 - - -### SDKErrorProcessor -The part of the SDK responsible for handling exceptions and triggering error-specific hooks. Catches and processes exceptions during SDK operations. Upon an error, it notifies the `SDKHookOrchestrator` to run `after_error` hooks. - - -**Related Classes/Methods**: - -- `friendli_core.SDKErrorProcessor`:12-39 - - -### Unclassified -Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) - - -**Related Classes/Methods**: _None_ - - - -### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 8106be7..dc78313 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -14,7 +14,8 @@ ], "assigned_files": [ "src/friendli/friendli.py", - "src/friendli/__init__.py" + "src/friendli/__init__.py", + "src/friendli_core/sdk.py" ], "can_expand": true }, @@ -33,8 +34,7 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/sdk.py", - "src/friendli_core/endpoint.py", + "src/friendli_core/_version.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -72,20 +72,15 @@ ], "assigned_files": [ "src/friendli/container/completions.py", - "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", "src/friendli/serverless/chat.py", "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", "src/friendli/serverless/token.py", "src/friendli/serverless/knowledge.py", "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", "src/friendli/dedicated/image.py", "src/friendli/dedicated/token.py", "src/friendli/dedicated/audio.py", @@ -93,16 +88,19 @@ "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", + "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", + "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -357,12 +355,15 @@ } ], "assigned_files": [ - "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli/container/__init__.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/model.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/endpoint.py", "src/friendli_core/dedicated.py", "src/friendli_core/container.py", - "src/friendli_core/friendlicore_serverless_token.py", - "src/friendli_core/serverless.py", - "src/friendli_core/friendlicore_serverless_completions.py" + "src/friendli_core/endpoint.py", + "src/friendli_core/serverless.py" ], "can_expand": true }, @@ -383,7 +384,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": true + "can_expand": false }, { "name": "Unclassified", @@ -391,7 +392,6 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", - "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -463,6 +463,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 1917a2b..f931f3f 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "c098d4cf4fef2de945984f3f69232dbbfa5b882e", + "commit_hash": "60cff9cc1e4b5f31db88108b2281c75b49aa1555", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 626cd13..5173f3a 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -15,6 +15,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -26,7 +27,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -84,7 +84,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -145,6 +145,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 73168bd..c8b326b 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -179,3 +179,11 @@ _Last updated: 2025-11-08 20:30:16 UTC_ - [overview.md](./overview.md) _Last updated: 2025-11-15 20:35:14 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-11-22 20:33:01 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 626cd13..5173f3a 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -15,6 +15,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -26,7 +27,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -84,7 +84,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -145,6 +145,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From e84916952832b816d1b295902445036f49102019 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 29 Nov 2025 20:36:48 +0000 Subject: [PATCH 21/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 49 ++++++++++++++++ .codeboarding/Hooks_Extensibility.md | 33 +++++++++++ .codeboarding/analysis.json | 29 ++++++---- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 +++- docs/architecture/Hooks_Extensibility.md | 74 +++--------------------- docs/architecture/on_boarding.md | 9 +++ docs/architecture/overview.md | 10 +++- 8 files changed, 135 insertions(+), 81 deletions(-) create mode 100644 .codeboarding/Hooks_Extensibility.json create mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json new file mode 100644 index 0000000..501a238 --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.json @@ -0,0 +1,49 @@ +{ + "description": "The `friendli_core` SDK is designed with extensibility in mind, primarily through its `Hooks & Extensibility Manager`. This central component, embodied by classes like `HookRegistrar` and `SDKHooks`, facilitates the dynamic registration and execution of custom logic. The `HookRegistrar` acts as the entry point for defining new hooks, while `SDKHooks` provides the mechanism for the SDK's core functionalities to discover and invoke these registered hooks at predetermined points. This architecture ensures that the SDK remains flexible and adaptable, allowing for easy integration of custom behaviors and extensions without altering the core codebase.", + "components": [ + { + "name": "Hooks & Extensibility Manager", + "description": "This component is responsible for managing the registration, discovery, and execution of various custom logic hooks throughout the SDK's lifecycle. It provides the core mechanism for extensibility.", + "referenced_source_code": [ + { + "qualified_name": "friendli_core._hooks.registration.HookRegistrar", + "reference_file": "", + "reference_start_line": null, + "reference_end_line": null + }, + { + "qualified_name": "friendli_core._hooks.sdkhooks.SDKHooks", + "reference_file": "src/friendli_core/_hooks/sdkhooks.py", + "reference_start_line": 22, + "reference_end_line": 79 + } + ], + "assigned_files": [ + "src/friendli_core/_hooks/__init__.py", + "src/friendli_core/_hooks/sdkhooks.py", + "src/friendli_core/_hooks/registration.py", + "src/friendli_core/_hooks/types.py" + ], + "can_expand": true + }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + } + ], + "components_relations": [ + { + "relation": "Registers Hooks", + "src_name": "Hooks & Extensibility Manager", + "dst_name": "SDK Core" + }, + { + "relation": "Triggers Hooks", + "src_name": "SDK Core", + "dst_name": "Hooks & Extensibility Manager" + } + ] +} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md new file mode 100644 index 0000000..3bd4498 --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.md @@ -0,0 +1,33 @@ +```mermaid +graph LR + Hooks_Extensibility_Manager["Hooks & Extensibility Manager"] + Unclassified["Unclassified"] + Hooks_Extensibility_Manager -- "Registers Hooks" --> SDK_Core + SDK_Core -- "Triggers Hooks" --> Hooks_Extensibility_Manager +``` + +[![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) + +## Details + +The `friendli_core` SDK is designed with extensibility in mind, primarily through its `Hooks & Extensibility Manager`. This central component, embodied by classes like `HookRegistrar` and `SDKHooks`, facilitates the dynamic registration and execution of custom logic. The `HookRegistrar` acts as the entry point for defining new hooks, while `SDKHooks` provides the mechanism for the SDK's core functionalities to discover and invoke these registered hooks at predetermined points. This architecture ensures that the SDK remains flexible and adaptable, allowing for easy integration of custom behaviors and extensions without altering the core codebase. + +### Hooks & Extensibility Manager +This component is responsible for managing the registration, discovery, and execution of various custom logic hooks throughout the SDK's lifecycle. It provides the core mechanism for extensibility. + + +**Related Classes/Methods**: + +- `friendli_core._hooks.registration.HookRegistrar` +- `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 + + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + +**Related Classes/Methods**: _None_ + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index dc78313..5f9d146 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -34,7 +34,7 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/_version.py", + "src/friendli_core/endpoint.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -88,19 +88,16 @@ "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", - "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -121,6 +118,7 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli/serverless/model.py", "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", @@ -331,9 +329,7 @@ "src/friendli_core/models/init_uploadop.py", "src/friendli_core/models/streamedchatdata.py", "src/friendli_core/models/fileinfo.py", - "src/friendli_core/models/streamedcompletiondata.py", - "src/friendli_core/types/__init__.py", - "src/friendli_core/types/basemodel.py" + "src/friendli_core/models/streamedcompletiondata.py" ], "can_expand": true }, @@ -357,13 +353,14 @@ "assigned_files": [ "src/friendli/container/__init__.py", "src/friendli/serverless/__init__.py", - "src/friendli/serverless/model.py", "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/endpoint.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/dedicated.py", "src/friendli_core/container.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/serverless.py" + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/serverless.py", + "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true }, @@ -384,7 +381,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": false + "can_expand": true }, { "name": "Unclassified", @@ -392,6 +389,7 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", + "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -409,6 +407,8 @@ "src/friendli_core/utils/unmarshal_json_response.py", "src/friendli_core/utils/eventstreaming.py", "src/friendli_core/utils/annotations.py", + "src/friendli_core/types/__init__.py", + "src/friendli_core/types/basemodel.py", "scripts/prepare_readme.py", "scripts/auto-fix.py" ], @@ -470,6 +470,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index f931f3f..01273ad 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "60cff9cc1e4b5f31db88108b2281c75b49aa1555", + "commit_hash": "2fdc7274073734394c843c58e6c409cd8b275630", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 5173f3a..bd30a19 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -16,6 +16,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -27,6 +28,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -84,7 +86,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -151,6 +153,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/Hooks_Extensibility.md b/docs/architecture/Hooks_Extensibility.md index 9a68b91..3bd4498 100644 --- a/docs/architecture/Hooks_Extensibility.md +++ b/docs/architecture/Hooks_Extensibility.md @@ -1,87 +1,27 @@ ```mermaid graph LR - FriendliClient["FriendliClient"] - HookRegistrar["HookRegistrar"] - SDKHookOrchestrator["SDKHookOrchestrator"] - HookDefinitions["HookDefinitions"] - HttpClient["HttpClient"] - SDKErrorProcessor["SDKErrorProcessor"] + Hooks_Extensibility_Manager["Hooks & Extensibility Manager"] Unclassified["Unclassified"] - SDKHookOrchestrator -- "implements" --> HookDefinitions - HookRegistrar -- "configures" --> SDKHookOrchestrator - SDKHookOrchestrator -- "uses" --> HookDefinitions - FriendliClient -- "registers hooks with" --> HookRegistrar - HookRegistrar -- "registers hooks with" --> SDKHookOrchestrator - HttpClient -- "invokes before_request hooks on" --> SDKHookOrchestrator - HttpClient -- "invokes after_success hooks on" --> SDKHookOrchestrator - SDKErrorProcessor -- "invokes after_error hooks on" --> SDKHookOrchestrator + Hooks_Extensibility_Manager -- "Registers Hooks" --> SDK_Core + SDK_Core -- "Triggers Hooks" --> Hooks_Extensibility_Manager ``` [![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) ## Details -The `friendli_core._hooks` subsystem provides a robust extension mechanism for the Friendli SDK. The `FriendliClient` initiates this by providing custom logic to the `HookRegistrar`, which then configures the `SDKHookOrchestrator`. This orchestrator is central to the subsystem, managing and invoking various hook types—defined by `HookDefinitions`—at critical junctures. For instance, the `HttpClient` triggers hooks before sending requests and after receiving responses, while the `SDKErrorProcessor` activates specific hooks when exceptions occur. This design allows for flexible customization of SDK behavior without altering its core implementation, enhancing adaptability and maintainability. +The `friendli_core` SDK is designed with extensibility in mind, primarily through its `Hooks & Extensibility Manager`. This central component, embodied by classes like `HookRegistrar` and `SDKHooks`, facilitates the dynamic registration and execution of custom logic. The `HookRegistrar` acts as the entry point for defining new hooks, while `SDKHooks` provides the mechanism for the SDK's core functionalities to discover and invoke these registered hooks at predetermined points. This architecture ensures that the SDK remains flexible and adaptable, allowing for easy integration of custom behaviors and extensions without altering the core codebase. -### FriendliClient -The primary interface for users to interact with the SDK and register custom extensions. Initializes the SDK and provides custom hook implementations to the `HookRegistrar`. - - -**Related Classes/Methods**: - -- `friendli_core.FriendliClient` - - -### HookRegistrar -The component responsible for receiving and organizing custom hook implementations. Receives custom hook instances from `FriendliClient` and adds them to the `SDKHookOrchestrator` for later invocation. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.registration.init_hooks`:8-12 - - -### SDKHookOrchestrator -The central component that manages the lifecycle of hooks, invoking them at appropriate stages of SDK operations. Stores and manages different types of hooks. It is responsible for invoking the correct hooks (e.g., `before_request`, `after_success`, `after_error`) when triggered by `HttpClient` or `SDKErrorProcessor`, ensuring they adhere to `HookDefinitions`. +### Hooks & Extensibility Manager +This component is responsible for managing the registration, discovery, and execution of various custom logic hooks throughout the SDK's lifecycle. It provides the core mechanism for extensibility. **Related Classes/Methods**: +- `friendli_core._hooks.registration.HookRegistrar` - `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 -### HookDefinitions -The collection of abstract interfaces and data structures that define the contract and context for all types of hooks. Defines the abstract base classes for various hook types (e.g., `SDKInitHook`, `BeforeRequestHook`) and their associated context objects, establishing the API for custom extensions. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.types.Hooks`:100-115 -- `friendli_core._hooks.types.SDKInitHook`:67-70 -- `friendli_core._hooks.types.BeforeRequestHook`:73-78 -- `friendli_core._hooks.types.AfterSuccessHook`:81-86 -- `friendli_core._hooks.types.AfterErrorHook`:89-97 -- `friendli_core._hooks.types.HookContext`:12-31 - - -### HttpClient -The underlying mechanism for making external network requests, which integrates with the hook system. Executes network requests. Before sending a request, it notifies the `SDKHookOrchestrator` to run `before_request` hooks. After receiving a response, it notifies the `SDKHookOrchestrator` to run `after_success` hooks. - - -**Related Classes/Methods**: - -- `friendli_core.httpclient.HttpClient`:11-47 - - -### SDKErrorProcessor -The part of the SDK responsible for handling exceptions and triggering error-specific hooks. Catches and processes exceptions during SDK operations. Upon an error, it notifies the `SDKHookOrchestrator` to run `after_error` hooks. - - -**Related Classes/Methods**: - -- `friendli_core.SDKErrorProcessor`:12-39 - - ### Unclassified Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index c8b326b..e6b57ef 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -187,3 +187,12 @@ _Last updated: 2025-11-15 20:35:14 UTC_ - [overview.md](./overview.md) _Last updated: 2025-11-22 20:33:01 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-11-29 20:36:48 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 5173f3a..bd30a19 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -16,6 +16,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -27,6 +28,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -84,7 +86,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -151,6 +153,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 36f82c7b56678d72ef95d92674d6755e609be968 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 6 Dec 2025 20:34:16 +0000 Subject: [PATCH 22/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 13 ++------- .codeboarding/analysis.json | 37 ++++++++++++------------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++++ docs/architecture/on_boarding.md | 9 ++++++ docs/architecture/overview.md | 7 +++++ 6 files changed, 44 insertions(+), 31 deletions(-) diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json index 501a238..434edc1 100644 --- a/.codeboarding/Hooks_Extensibility.json +++ b/.codeboarding/Hooks_Extensibility.json @@ -17,21 +17,12 @@ "reference_start_line": 22, "reference_end_line": 79 } - ], - "assigned_files": [ - "src/friendli_core/_hooks/__init__.py", - "src/friendli_core/_hooks/sdkhooks.py", - "src/friendli_core/_hooks/registration.py", - "src/friendli_core/_hooks/types.py" - ], - "can_expand": true + ] }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", - "referenced_source_code": [], - "assigned_files": [], - "can_expand": false + "referenced_source_code": [] } ], "components_relations": [ diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 5f9d146..7789c1f 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -14,8 +14,7 @@ ], "assigned_files": [ "src/friendli/friendli.py", - "src/friendli/__init__.py", - "src/friendli_core/sdk.py" + "src/friendli/__init__.py" ], "can_expand": true }, @@ -34,8 +33,6 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" ], @@ -72,15 +69,20 @@ ], "assigned_files": [ "src/friendli/container/completions.py", + "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", "src/friendli/serverless/completions.py", + "src/friendli/serverless/__init__.py", "src/friendli/serverless/chat.py", "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", "src/friendli/serverless/token.py", "src/friendli/serverless/knowledge.py", "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", "src/friendli/dedicated/image.py", "src/friendli/dedicated/token.py", "src/friendli/dedicated/audio.py", @@ -88,14 +90,11 @@ "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/completions.py", "src/friendli_core/file.py", - "src/friendli_core/chat.py", + "src/friendli_core/container.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", - "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", "src/friendli_core/friendlicore_chat.py", @@ -118,7 +117,6 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", - "src/friendli/serverless/model.py", "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", @@ -329,7 +327,9 @@ "src/friendli_core/models/init_uploadop.py", "src/friendli_core/models/streamedchatdata.py", "src/friendli_core/models/fileinfo.py", - "src/friendli_core/models/streamedcompletiondata.py" + "src/friendli_core/models/streamedcompletiondata.py", + "src/friendli_core/types/__init__.py", + "src/friendli_core/types/basemodel.py" ], "can_expand": true }, @@ -351,15 +351,9 @@ } ], "assigned_files": [ - "src/friendli/container/__init__.py", - "src/friendli/serverless/__init__.py", - "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/endpoint.py", "src/friendli_core/friendlicore_serverless_chat.py", - "src/friendli_core/dedicated.py", - "src/friendli_core/container.py", + "src/friendli_core/endpoint.py", "src/friendli_core/friendlicore_serverless_token.py", - "src/friendli_core/serverless.py", "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true @@ -407,8 +401,6 @@ "src/friendli_core/utils/unmarshal_json_response.py", "src/friendli_core/utils/eventstreaming.py", "src/friendli_core/utils/annotations.py", - "src/friendli_core/types/__init__.py", - "src/friendli_core/types/basemodel.py", "scripts/prepare_readme.py", "scripts/auto-fix.py" ], @@ -477,6 +469,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 01273ad..6b3a15d 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "2fdc7274073734394c843c58e6c409cd8b275630", + "commit_hash": "e84916952832b816d1b295902445036f49102019", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index bd30a19..bd75711 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -17,6 +17,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -159,6 +160,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index e6b57ef..5f6a9ad 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -196,3 +196,12 @@ _Last updated: 2025-11-22 20:33:01 UTC_ - [overview.md](./overview.md) _Last updated: 2025-11-29 20:36:48 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-12-06 20:34:16 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index bd30a19..bd75711 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -17,6 +17,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -159,6 +160,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From e7eed5910100aa72f1415e6a5c01b1c6b40c0f4d Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 13 Dec 2025 20:34:17 +0000 Subject: [PATCH 23/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 35 ++++++++++++++++++------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++++ docs/architecture/on_boarding.md | 9 +++++++ docs/architecture/overview.md | 7 +++++ 5 files changed, 49 insertions(+), 11 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 7789c1f..6043259 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -14,7 +14,8 @@ ], "assigned_files": [ "src/friendli/friendli.py", - "src/friendli/__init__.py" + "src/friendli/__init__.py", + "src/friendli_core/sdk.py" ], "can_expand": true }, @@ -33,6 +34,7 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", + "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" ], @@ -69,20 +71,15 @@ ], "assigned_files": [ "src/friendli/container/completions.py", - "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", "src/friendli/serverless/completions.py", - "src/friendli/serverless/__init__.py", "src/friendli/serverless/chat.py", "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", "src/friendli/serverless/token.py", "src/friendli/serverless/knowledge.py", "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", "src/friendli/dedicated/image.py", "src/friendli/dedicated/token.py", "src/friendli/dedicated/audio.py", @@ -90,13 +87,19 @@ "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", + "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli_core/completions.py", "src/friendli_core/file.py", - "src/friendli_core/container.py", + "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", + "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", + "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -351,10 +354,15 @@ } ], "assigned_files": [ - "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli/container/__init__.py", + "src/friendli/serverless/__init__.py", + "src/friendli/serverless/model.py", + "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli_core/dedicated.py", + "src/friendli_core/container.py", "src/friendli_core/endpoint.py", - "src/friendli_core/friendlicore_serverless_token.py", - "src/friendli_core/friendlicore_serverless_completions.py" + "src/friendli_core/serverless.py" ], "can_expand": true }, @@ -476,6 +484,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 6b3a15d..34a2602 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "e84916952832b816d1b295902445036f49102019", + "commit_hash": "36f82c7b56678d72ef95d92674d6755e609be968", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index bd75711..2636903 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -18,6 +18,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -166,6 +167,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 5f6a9ad..72bedce 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -205,3 +205,12 @@ _Last updated: 2025-11-29 20:36:48 UTC_ - [overview.md](./overview.md) _Last updated: 2025-12-06 20:34:16 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-12-13 20:34:17 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index bd75711..2636903 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -18,6 +18,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -166,6 +167,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 6fa0232f76cebbfe1987ee0dd5a0d0b997533a5e Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 20 Dec 2025 20:34:05 +0000 Subject: [PATCH 24/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 19 +++++++++++++------ .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++++++ docs/architecture/on_boarding.md | 9 +++++++++ docs/architecture/overview.md | 7 +++++++ 5 files changed, 37 insertions(+), 7 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 6043259..119e757 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -31,11 +31,8 @@ } ], "assigned_files": [ - "src/friendli/httpclient.py", - "src/friendli/config.py", "src/friendli_core/__init__.py", "src/friendli_core/basesdk.py", - "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" ], "can_expand": true @@ -71,6 +68,7 @@ ], "assigned_files": [ "src/friendli/container/completions.py", + "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", "src/friendli/serverless/completions.py", @@ -90,6 +88,7 @@ "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", + "src/friendli_core/container.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", @@ -120,6 +119,7 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli/serverless/model.py", "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", @@ -354,13 +354,10 @@ } ], "assigned_files": [ - "src/friendli/container/__init__.py", "src/friendli/serverless/__init__.py", - "src/friendli/serverless/model.py", "src/friendli/dedicated/__init__.py", "src/friendli/dedicated/endpoint.py", "src/friendli_core/dedicated.py", - "src/friendli_core/container.py", "src/friendli_core/endpoint.py", "src/friendli_core/serverless.py" ], @@ -391,7 +388,10 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", + "src/friendli/httpclient.py", + "src/friendli/config.py", "src/friendli_core/_version.py", + "src/friendli_core/httpclient.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -491,6 +491,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 34a2602..21a5ab2 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "36f82c7b56678d72ef95d92674d6755e609be968", + "commit_hash": "e7eed5910100aa72f1415e6a5c01b1c6b40c0f4d", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 2636903..59d962c 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -19,6 +19,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -173,6 +174,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 72bedce..429ccf9 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -214,3 +214,12 @@ _Last updated: 2025-12-06 20:34:16 UTC_ - [overview.md](./overview.md) _Last updated: 2025-12-13 20:34:17 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-12-20 20:34:05 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 2636903..59d962c 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -19,6 +19,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -173,6 +174,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From af5799dbe50e9c10b483353ee8a8925f6a0aba69 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 27 Dec 2025 20:35:57 +0000 Subject: [PATCH 25/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 6 - JSON files created/updated: 7 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 40 ------------------------- .codeboarding/Hooks_Extensibility.md | 33 -------------------- .codeboarding/analysis.json | 27 ++++++++++------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 +++++-- docs/architecture/on_boarding.md | 8 +++++ docs/architecture/overview.md | 10 +++++-- 7 files changed, 42 insertions(+), 88 deletions(-) delete mode 100644 .codeboarding/Hooks_Extensibility.json delete mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json deleted file mode 100644 index 434edc1..0000000 --- a/.codeboarding/Hooks_Extensibility.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "description": "The `friendli_core` SDK is designed with extensibility in mind, primarily through its `Hooks & Extensibility Manager`. This central component, embodied by classes like `HookRegistrar` and `SDKHooks`, facilitates the dynamic registration and execution of custom logic. The `HookRegistrar` acts as the entry point for defining new hooks, while `SDKHooks` provides the mechanism for the SDK's core functionalities to discover and invoke these registered hooks at predetermined points. This architecture ensures that the SDK remains flexible and adaptable, allowing for easy integration of custom behaviors and extensions without altering the core codebase.", - "components": [ - { - "name": "Hooks & Extensibility Manager", - "description": "This component is responsible for managing the registration, discovery, and execution of various custom logic hooks throughout the SDK's lifecycle. It provides the core mechanism for extensibility.", - "referenced_source_code": [ - { - "qualified_name": "friendli_core._hooks.registration.HookRegistrar", - "reference_file": "", - "reference_start_line": null, - "reference_end_line": null - }, - { - "qualified_name": "friendli_core._hooks.sdkhooks.SDKHooks", - "reference_file": "src/friendli_core/_hooks/sdkhooks.py", - "reference_start_line": 22, - "reference_end_line": 79 - } - ] - }, - { - "name": "Unclassified", - "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", - "referenced_source_code": [] - } - ], - "components_relations": [ - { - "relation": "Registers Hooks", - "src_name": "Hooks & Extensibility Manager", - "dst_name": "SDK Core" - }, - { - "relation": "Triggers Hooks", - "src_name": "SDK Core", - "dst_name": "Hooks & Extensibility Manager" - } - ] -} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md deleted file mode 100644 index 3bd4498..0000000 --- a/.codeboarding/Hooks_Extensibility.md +++ /dev/null @@ -1,33 +0,0 @@ -```mermaid -graph LR - Hooks_Extensibility_Manager["Hooks & Extensibility Manager"] - Unclassified["Unclassified"] - Hooks_Extensibility_Manager -- "Registers Hooks" --> SDK_Core - SDK_Core -- "Triggers Hooks" --> Hooks_Extensibility_Manager -``` - -[![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) - -## Details - -The `friendli_core` SDK is designed with extensibility in mind, primarily through its `Hooks & Extensibility Manager`. This central component, embodied by classes like `HookRegistrar` and `SDKHooks`, facilitates the dynamic registration and execution of custom logic. The `HookRegistrar` acts as the entry point for defining new hooks, while `SDKHooks` provides the mechanism for the SDK's core functionalities to discover and invoke these registered hooks at predetermined points. This architecture ensures that the SDK remains flexible and adaptable, allowing for easy integration of custom behaviors and extensions without altering the core codebase. - -### Hooks & Extensibility Manager -This component is responsible for managing the registration, discovery, and execution of various custom logic hooks throughout the SDK's lifecycle. It provides the core mechanism for extensibility. - - -**Related Classes/Methods**: - -- `friendli_core._hooks.registration.HookRegistrar` -- `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 - - -### Unclassified -Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) - - -**Related Classes/Methods**: _None_ - - - -### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 119e757..124f53e 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -31,8 +31,10 @@ } ], "assigned_files": [ - "src/friendli_core/__init__.py", + "src/friendli/httpclient.py", + "src/friendli/config.py", "src/friendli_core/basesdk.py", + "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" ], "can_expand": true @@ -68,16 +70,17 @@ ], "assigned_files": [ "src/friendli/container/completions.py", - "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", "src/friendli/serverless/completions.py", "src/friendli/serverless/chat.py", "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", "src/friendli/serverless/token.py", "src/friendli/serverless/knowledge.py", "src/friendli/dedicated/completions.py", "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", "src/friendli/dedicated/image.py", "src/friendli/dedicated/token.py", "src/friendli/dedicated/audio.py", @@ -92,8 +95,10 @@ "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", + "src/friendli_core/endpoint.py", "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", + "src/friendli_core/model.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", @@ -119,8 +124,6 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", - "src/friendli/serverless/model.py", - "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -354,11 +357,10 @@ } ], "assigned_files": [ + "src/friendli/container/__init__.py", "src/friendli/serverless/__init__.py", "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/endpoint.py", "src/friendli_core/dedicated.py", - "src/friendli_core/endpoint.py", "src/friendli_core/serverless.py" ], "can_expand": true @@ -380,7 +382,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": true + "can_expand": false }, { "name": "Unclassified", @@ -388,10 +390,8 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", - "src/friendli/httpclient.py", - "src/friendli/config.py", + "src/friendli_core/__init__.py", "src/friendli_core/_version.py", - "src/friendli_core/httpclient.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -498,6 +498,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 21a5ab2..05a1a82 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "e7eed5910100aa72f1415e6a5c01b1c6b40c0f4d", + "commit_hash": "6fa0232f76cebbfe1987ee0dd5a0d0b997533a5e", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 59d962c..aeb221b 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -20,6 +20,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -31,7 +32,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -89,7 +89,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -180,6 +180,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 429ccf9..8d23c21 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -223,3 +223,11 @@ _Last updated: 2025-12-13 20:34:17 UTC_ - [overview.md](./overview.md) _Last updated: 2025-12-20 20:34:05 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2025-12-27 20:35:57 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 59d962c..aeb221b 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -20,6 +20,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -31,7 +32,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -89,7 +89,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -180,6 +180,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 2ea1468f7385a75bb6be9fa534a1219fb6882458 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 3 Jan 2026 20:39:50 +0000 Subject: [PATCH 26/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 105 +++++++++++++++++++++++ .codeboarding/Hooks_Extensibility.md | 66 ++++++++++++++ .codeboarding/analysis.json | 51 ++++++----- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 ++- docs/architecture/Hooks_Extensibility.md | 49 +++++++++-- docs/architecture/on_boarding.md | 9 ++ docs/architecture/overview.md | 10 ++- 8 files changed, 269 insertions(+), 33 deletions(-) create mode 100644 .codeboarding/Hooks_Extensibility.json create mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json new file mode 100644 index 0000000..fd2bd3c --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.json @@ -0,0 +1,105 @@ +{ + "description": "This graph represents the core functionality of a system that processes user queries, generates responses using a language model, and stores interaction history. The main flow involves receiving a query, retrieving relevant information, generating a response, and then saving the interaction. Its purpose is to provide an interactive question-answering system with memory.", + "components": [ + { + "name": "Query Processor", + "description": "Handles incoming user queries and prepares them for further processing.", + "referenced_source_code": [ + { + "qualified_name": "QueryHandler.process", + "reference_file": "query_handler.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "assigned_files": [], + "can_expand": true + }, + { + "name": "Information Retriever", + "description": "Fetches relevant information based on the processed query from a knowledge base.", + "referenced_source_code": [ + { + "qualified_name": "KnowledgeBase.retrieve", + "reference_file": "src/friendli_core/knowledge.py", + "reference_start_line": 20, + "reference_end_line": 115 + } + ], + "assigned_files": [], + "can_expand": false + }, + { + "name": "Response Generator", + "description": "Utilizes a language model to generate a natural language response.", + "referenced_source_code": [ + { + "qualified_name": "LanguageModel.generate_response", + "reference_file": "src/friendli_core/model.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "assigned_files": [], + "can_expand": true + }, + { + "name": "History Logger", + "description": "Stores the user query and the generated response for future reference.", + "referenced_source_code": [ + { + "qualified_name": "InteractionLogger.log", + "reference_file": "src/friendli_core/utils/logger.py", + "reference_start_line": null, + "reference_end_line": null + } + ], + "assigned_files": [], + "can_expand": false + }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [ + "src/friendli_core/_hooks/__init__.py", + "src/friendli_core/_hooks/sdkhooks.py", + "src/friendli_core/_hooks/registration.py", + "src/friendli_core/_hooks/types.py" + ], + "can_expand": false + } + ], + "components_relations": [ + { + "relation": "sends query to", + "src_name": "Query Processor", + "dst_name": "Information Retriever" + }, + { + "relation": "sends info to", + "src_name": "Information Retriever", + "dst_name": "Response Generator" + }, + { + "relation": "sends response to", + "src_name": "Response Generator", + "dst_name": "History Logger" + }, + { + "relation": "receives query from", + "src_name": "Information Retriever", + "dst_name": "Query Processor" + }, + { + "relation": "receives info from", + "src_name": "Response Generator", + "dst_name": "Information Retriever" + }, + { + "relation": "receives response from", + "src_name": "History Logger", + "dst_name": "Response Generator" + } + ] +} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md new file mode 100644 index 0000000..a615f66 --- /dev/null +++ b/.codeboarding/Hooks_Extensibility.md @@ -0,0 +1,66 @@ +```mermaid +graph LR + Query_Processor["Query Processor"] + Information_Retriever["Information Retriever"] + Response_Generator["Response Generator"] + History_Logger["History Logger"] + Unclassified["Unclassified"] + Query_Processor -- "sends query to" --> Information_Retriever + Information_Retriever -- "sends info to" --> Response_Generator + Response_Generator -- "sends response to" --> History_Logger + Information_Retriever -- "receives query from" --> Query_Processor + Response_Generator -- "receives info from" --> Information_Retriever + History_Logger -- "receives response from" --> Response_Generator +``` + +[![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) + +## Details + +This graph represents the core functionality of a system that processes user queries, generates responses using a language model, and stores interaction history. The main flow involves receiving a query, retrieving relevant information, generating a response, and then saving the interaction. Its purpose is to provide an interactive question-answering system with memory. + +### Query Processor +Handles incoming user queries and prepares them for further processing. + + +**Related Classes/Methods**: + +- `QueryHandler.process` + + +### Information Retriever +Fetches relevant information based on the processed query from a knowledge base. + + +**Related Classes/Methods**: + +- `KnowledgeBase.retrieve`:20-115 + + +### Response Generator +Utilizes a language model to generate a natural language response. + + +**Related Classes/Methods**: + +- `LanguageModel.generate_response` + + +### History Logger +Stores the user query and the generated response for future reference. + + +**Related Classes/Methods**: + +- `InteractionLogger.log` + + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + +**Related Classes/Methods**: _None_ + + + +### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 124f53e..95246f1 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -33,6 +33,8 @@ "assigned_files": [ "src/friendli/httpclient.py", "src/friendli/config.py", + "src/friendli_core/__init__.py", + "src/friendli_core/endpoint.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -70,40 +72,23 @@ ], "assigned_files": [ "src/friendli/container/completions.py", + "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", - "src/friendli/serverless/completions.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", - "src/friendli_core/container.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/image.py", - "src/friendli_core/model.py", "src/friendli_core/toolassistedchat.py", "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", - "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -124,6 +109,7 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -357,11 +343,26 @@ } ], "assigned_files": [ - "src/friendli/container/__init__.py", + "src/friendli/serverless/completions.py", "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", "src/friendli/dedicated/__init__.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/dedicated.py", - "src/friendli_core/serverless.py" + "src/friendli_core/container.py", + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/serverless.py", + "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true }, @@ -382,7 +383,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": false + "can_expand": true }, { "name": "Unclassified", @@ -390,7 +391,6 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", - "src/friendli_core/__init__.py", "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", @@ -505,6 +505,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 05a1a82..a394353 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "6fa0232f76cebbfe1987ee0dd5a0d0b997533a5e", + "commit_hash": "af5799dbe50e9c10b483353ee8a8925f6a0aba69", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index aeb221b..f9ab747 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -21,6 +21,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -32,6 +33,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -89,7 +91,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -186,6 +188,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/Hooks_Extensibility.md b/docs/architecture/Hooks_Extensibility.md index 3bd4498..a615f66 100644 --- a/docs/architecture/Hooks_Extensibility.md +++ b/docs/architecture/Hooks_Extensibility.md @@ -1,25 +1,58 @@ ```mermaid graph LR - Hooks_Extensibility_Manager["Hooks & Extensibility Manager"] + Query_Processor["Query Processor"] + Information_Retriever["Information Retriever"] + Response_Generator["Response Generator"] + History_Logger["History Logger"] Unclassified["Unclassified"] - Hooks_Extensibility_Manager -- "Registers Hooks" --> SDK_Core - SDK_Core -- "Triggers Hooks" --> Hooks_Extensibility_Manager + Query_Processor -- "sends query to" --> Information_Retriever + Information_Retriever -- "sends info to" --> Response_Generator + Response_Generator -- "sends response to" --> History_Logger + Information_Retriever -- "receives query from" --> Query_Processor + Response_Generator -- "receives info from" --> Information_Retriever + History_Logger -- "receives response from" --> Response_Generator ``` [![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) ## Details -The `friendli_core` SDK is designed with extensibility in mind, primarily through its `Hooks & Extensibility Manager`. This central component, embodied by classes like `HookRegistrar` and `SDKHooks`, facilitates the dynamic registration and execution of custom logic. The `HookRegistrar` acts as the entry point for defining new hooks, while `SDKHooks` provides the mechanism for the SDK's core functionalities to discover and invoke these registered hooks at predetermined points. This architecture ensures that the SDK remains flexible and adaptable, allowing for easy integration of custom behaviors and extensions without altering the core codebase. +This graph represents the core functionality of a system that processes user queries, generates responses using a language model, and stores interaction history. The main flow involves receiving a query, retrieving relevant information, generating a response, and then saving the interaction. Its purpose is to provide an interactive question-answering system with memory. -### Hooks & Extensibility Manager -This component is responsible for managing the registration, discovery, and execution of various custom logic hooks throughout the SDK's lifecycle. It provides the core mechanism for extensibility. +### Query Processor +Handles incoming user queries and prepares them for further processing. **Related Classes/Methods**: -- `friendli_core._hooks.registration.HookRegistrar` -- `friendli_core._hooks.sdkhooks.SDKHooks`:22-79 +- `QueryHandler.process` + + +### Information Retriever +Fetches relevant information based on the processed query from a knowledge base. + + +**Related Classes/Methods**: + +- `KnowledgeBase.retrieve`:20-115 + + +### Response Generator +Utilizes a language model to generate a natural language response. + + +**Related Classes/Methods**: + +- `LanguageModel.generate_response` + + +### History Logger +Stores the user query and the generated response for future reference. + + +**Related Classes/Methods**: + +- `InteractionLogger.log` ### Unclassified diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 8d23c21..b0b7c7f 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -231,3 +231,12 @@ _Last updated: 2025-12-20 20:34:05 UTC_ - [overview.md](./overview.md) _Last updated: 2025-12-27 20:35:57 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2026-01-03 20:39:50 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index aeb221b..f9ab747 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -21,6 +21,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -32,6 +33,7 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" + click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -89,7 +91,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility +### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -186,6 +188,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 6a93a3a37493a4fe3835b9f93030664d9f895966 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 10 Jan 2026 20:36:29 +0000 Subject: [PATCH 27/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 7 - JSON files created/updated: 8 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 25 +++++-------------------- .codeboarding/analysis.json | 11 +++++++++-- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++++++ docs/architecture/on_boarding.md | 9 +++++++++ docs/architecture/overview.md | 7 +++++++ 6 files changed, 38 insertions(+), 23 deletions(-) diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json index fd2bd3c..faf3a1d 100644 --- a/.codeboarding/Hooks_Extensibility.json +++ b/.codeboarding/Hooks_Extensibility.json @@ -11,9 +11,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "assigned_files": [], - "can_expand": true + ] }, { "name": "Information Retriever", @@ -25,9 +23,7 @@ "reference_start_line": 20, "reference_end_line": 115 } - ], - "assigned_files": [], - "can_expand": false + ] }, { "name": "Response Generator", @@ -39,9 +35,7 @@ "reference_start_line": null, "reference_end_line": null } - ], - "assigned_files": [], - "can_expand": true + ] }, { "name": "History Logger", @@ -53,21 +47,12 @@ "reference_start_line": null, "reference_end_line": null } - ], - "assigned_files": [], - "can_expand": false + ] }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", - "referenced_source_code": [], - "assigned_files": [ - "src/friendli_core/_hooks/__init__.py", - "src/friendli_core/_hooks/sdkhooks.py", - "src/friendli_core/_hooks/registration.py", - "src/friendli_core/_hooks/types.py" - ], - "can_expand": false + "referenced_source_code": [] } ], "components_relations": [ diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index 95246f1..a849bc4 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -34,7 +34,6 @@ "src/friendli/httpclient.py", "src/friendli/config.py", "src/friendli_core/__init__.py", - "src/friendli_core/endpoint.py", "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", "src/friendli_core/sdkconfiguration.py" @@ -81,6 +80,7 @@ "src/friendli/file/file.py", "src/friendli_core/completions.py", "src/friendli_core/file.py", + "src/friendli_core/container.py", "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", @@ -359,7 +359,7 @@ "src/friendli/dedicated/audio.py", "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/dedicated.py", - "src/friendli_core/container.py", + "src/friendli_core/endpoint.py", "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/serverless.py", "src/friendli_core/friendlicore_serverless_completions.py" @@ -512,6 +512,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index a394353..5b91f7f 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "af5799dbe50e9c10b483353ee8a8925f6a0aba69", + "commit_hash": "2ea1468f7385a75bb6be9fa534a1219fb6882458", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index f9ab747..7eb5212 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -22,6 +22,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -194,6 +195,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index b0b7c7f..24e6f54 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -240,3 +240,12 @@ _Last updated: 2025-12-27 20:35:57 UTC_ - [overview.md](./overview.md) _Last updated: 2026-01-03 20:39:50 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Hooks_Extensibility.md](./Hooks_Extensibility.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2026-01-10 20:36:29 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index f9ab747..7eb5212 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -22,6 +22,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -194,6 +195,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 1def28d72026955db7b012597f0a488a89928ade Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 17 Jan 2026 20:36:12 +0000 Subject: [PATCH 28/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 6 - JSON files created/updated: 7 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/Hooks_Extensibility.json | 90 ------------------------- .codeboarding/Hooks_Extensibility.md | 66 ------------------ .codeboarding/analysis.json | 66 +++++++++--------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 10 ++- docs/architecture/on_boarding.md | 8 +++ docs/architecture/overview.md | 10 ++- 7 files changed, 61 insertions(+), 191 deletions(-) delete mode 100644 .codeboarding/Hooks_Extensibility.json delete mode 100644 .codeboarding/Hooks_Extensibility.md diff --git a/.codeboarding/Hooks_Extensibility.json b/.codeboarding/Hooks_Extensibility.json deleted file mode 100644 index faf3a1d..0000000 --- a/.codeboarding/Hooks_Extensibility.json +++ /dev/null @@ -1,90 +0,0 @@ -{ - "description": "This graph represents the core functionality of a system that processes user queries, generates responses using a language model, and stores interaction history. The main flow involves receiving a query, retrieving relevant information, generating a response, and then saving the interaction. Its purpose is to provide an interactive question-answering system with memory.", - "components": [ - { - "name": "Query Processor", - "description": "Handles incoming user queries and prepares them for further processing.", - "referenced_source_code": [ - { - "qualified_name": "QueryHandler.process", - "reference_file": "query_handler.py", - "reference_start_line": null, - "reference_end_line": null - } - ] - }, - { - "name": "Information Retriever", - "description": "Fetches relevant information based on the processed query from a knowledge base.", - "referenced_source_code": [ - { - "qualified_name": "KnowledgeBase.retrieve", - "reference_file": "src/friendli_core/knowledge.py", - "reference_start_line": 20, - "reference_end_line": 115 - } - ] - }, - { - "name": "Response Generator", - "description": "Utilizes a language model to generate a natural language response.", - "referenced_source_code": [ - { - "qualified_name": "LanguageModel.generate_response", - "reference_file": "src/friendli_core/model.py", - "reference_start_line": null, - "reference_end_line": null - } - ] - }, - { - "name": "History Logger", - "description": "Stores the user query and the generated response for future reference.", - "referenced_source_code": [ - { - "qualified_name": "InteractionLogger.log", - "reference_file": "src/friendli_core/utils/logger.py", - "reference_start_line": null, - "reference_end_line": null - } - ] - }, - { - "name": "Unclassified", - "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", - "referenced_source_code": [] - } - ], - "components_relations": [ - { - "relation": "sends query to", - "src_name": "Query Processor", - "dst_name": "Information Retriever" - }, - { - "relation": "sends info to", - "src_name": "Information Retriever", - "dst_name": "Response Generator" - }, - { - "relation": "sends response to", - "src_name": "Response Generator", - "dst_name": "History Logger" - }, - { - "relation": "receives query from", - "src_name": "Information Retriever", - "dst_name": "Query Processor" - }, - { - "relation": "receives info from", - "src_name": "Response Generator", - "dst_name": "Information Retriever" - }, - { - "relation": "receives response from", - "src_name": "History Logger", - "dst_name": "Response Generator" - } - ] -} diff --git a/.codeboarding/Hooks_Extensibility.md b/.codeboarding/Hooks_Extensibility.md deleted file mode 100644 index a615f66..0000000 --- a/.codeboarding/Hooks_Extensibility.md +++ /dev/null @@ -1,66 +0,0 @@ -```mermaid -graph LR - Query_Processor["Query Processor"] - Information_Retriever["Information Retriever"] - Response_Generator["Response Generator"] - History_Logger["History Logger"] - Unclassified["Unclassified"] - Query_Processor -- "sends query to" --> Information_Retriever - Information_Retriever -- "sends info to" --> Response_Generator - Response_Generator -- "sends response to" --> History_Logger - Information_Retriever -- "receives query from" --> Query_Processor - Response_Generator -- "receives info from" --> Information_Retriever - History_Logger -- "receives response from" --> Response_Generator -``` - -[![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) - -## Details - -This graph represents the core functionality of a system that processes user queries, generates responses using a language model, and stores interaction history. The main flow involves receiving a query, retrieving relevant information, generating a response, and then saving the interaction. Its purpose is to provide an interactive question-answering system with memory. - -### Query Processor -Handles incoming user queries and prepares them for further processing. - - -**Related Classes/Methods**: - -- `QueryHandler.process` - - -### Information Retriever -Fetches relevant information based on the processed query from a knowledge base. - - -**Related Classes/Methods**: - -- `KnowledgeBase.retrieve`:20-115 - - -### Response Generator -Utilizes a language model to generate a natural language response. - - -**Related Classes/Methods**: - -- `LanguageModel.generate_response` - - -### History Logger -Stores the user query and the generated response for future reference. - - -**Related Classes/Methods**: - -- `InteractionLogger.log` - - -### Unclassified -Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) - - -**Related Classes/Methods**: _None_ - - - -### [FAQ](https://github.com/CodeBoarding/GeneratedOnBoardings/tree/main?tab=readme-ov-file#faq) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index a849bc4..a83af94 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -13,9 +13,9 @@ } ], "assigned_files": [ + "/mnt/e/StartUp/friendli-python/src/friendli_core/sdk.py", "src/friendli/friendli.py", - "src/friendli/__init__.py", - "src/friendli_core/sdk.py" + "src/friendli/__init__.py" ], "can_expand": true }, @@ -31,12 +31,13 @@ } ], "assigned_files": [ - "src/friendli/httpclient.py", - "src/friendli/config.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", "src/friendli_core/__init__.py", - "src/friendli_core/basesdk.py", "src/friendli_core/httpclient.py", - "src/friendli_core/sdkconfiguration.py" + "src/friendli_core/sdkconfiguration.py", + "src/friendli/httpclient.py", + "src/friendli/config.py", + "src/friendli_core/_version.py" ], "can_expand": true }, @@ -70,25 +71,38 @@ } ], "assigned_files": [ + "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", "src/friendli/container/completions.py", "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", + "src/friendli/serverless/completions.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/completions.py", + "src/friendli_core/friendlicore_serverless_chat.py", "src/friendli_core/file.py", "src/friendli_core/container.py", - "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/image.py", + "src/friendli_core/friendlicore_serverless_token.py", "src/friendli_core/toolassistedchat.py", - "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", + "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -109,7 +123,6 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", - "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -343,26 +356,13 @@ } ], "assigned_files": [ - "src/friendli/serverless/completions.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", + "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py", + "src/friendli_core/endpoint.py", "src/friendli/serverless/__init__.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", "src/friendli/serverless/model.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/endpoint.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", - "src/friendli_core/friendlicore_serverless_chat.py", - "src/friendli_core/dedicated.py", - "src/friendli_core/endpoint.py", - "src/friendli_core/friendlicore_serverless_token.py", - "src/friendli_core/serverless.py", - "src/friendli_core/friendlicore_serverless_completions.py" + "src/friendli/dedicated/endpoint.py" ], "can_expand": true }, @@ -383,7 +383,7 @@ "src/friendli_core/_hooks/registration.py", "src/friendli_core/_hooks/types.py" ], - "can_expand": true + "can_expand": false }, { "name": "Unclassified", @@ -391,7 +391,6 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", - "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -519,6 +518,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 5b91f7f..6efd86d 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "2ea1468f7385a75bb6be9fa534a1219fb6882458", + "commit_hash": "6a93a3a37493a4fe3835b9f93030664d9f895966", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index 7eb5212..a5e72b9 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -23,6 +23,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -34,7 +35,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -92,7 +92,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -201,6 +201,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index 24e6f54..a75b277 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -249,3 +249,11 @@ _Last updated: 2026-01-03 20:39:50 UTC_ - [overview.md](./overview.md) _Last updated: 2026-01-10 20:36:29 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2026-01-17 20:36:12 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index 7eb5212..a5e72b9 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -23,6 +23,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -34,7 +35,6 @@ graph LR click Service_Modules href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Service_Modules.md" "Details" click Data_Models_Error_Handling href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Data_Models_Error_Handling.md" "Details" click Platform_Abstractions href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Platform_Abstractions.md" "Details" - click Hooks_Extensibility href "https://github.com/CodeBoarding/friendli-python/blob/main/.codeboarding/Hooks_Extensibility.md" "Details" ``` [![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) @@ -92,7 +92,7 @@ Provides base structures and interfaces tailored for different operational modes - `friendli_core.serverless` -### Hooks & Extensibility [[Expand]](./Hooks_Extensibility.md) +### Hooks & Extensibility Offers an extensible mechanism for injecting custom logic at various stages of the request/response lifecycle, allowing for pre-processing, post-processing, and error handling customization. @@ -201,6 +201,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ From 5687f0d0d2abfbd10420fa68219a4a5e2217d8ac Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Sat, 24 Jan 2026 20:36:21 +0000 Subject: [PATCH 29/29] docs: update codeboarding architecture documentation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## 📚 Architecture Documentation Update This commit contains updated documentation files fetched from the CodeBoarding service and copied to the architecture documentation section. ### 📊 Summary - Documentation files created/updated: 6 - JSON files created/updated: 7 - Documentation directory: .codeboarding/ - JSON directory: .codeboarding/ - Output format: .md - Repository analyzed: https://github.com/CodeBoarding/friendli-python - Destination: docs/architecture/ The generated .md files have been automatically copied to the architecture documentation section and referenced in on_boarding.md. 🤖 This commit was automatically generated by the CodeBoarding documentation update workflow. --- .codeboarding/analysis.json | 66 ++++++++++++++----------- .codeboarding/codeboarding_version.json | 2 +- .codeboarding/overview.md | 7 +++ docs/architecture/on_boarding.md | 8 +++ docs/architecture/overview.md | 7 +++ 5 files changed, 60 insertions(+), 30 deletions(-) diff --git a/.codeboarding/analysis.json b/.codeboarding/analysis.json index a83af94..f9e8470 100644 --- a/.codeboarding/analysis.json +++ b/.codeboarding/analysis.json @@ -13,9 +13,9 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/sdk.py", "src/friendli/friendli.py", - "src/friendli/__init__.py" + "src/friendli/__init__.py", + "src/friendli_core/sdk.py" ], "can_expand": true }, @@ -31,13 +31,13 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/basesdk.py", - "src/friendli_core/__init__.py", - "src/friendli_core/httpclient.py", - "src/friendli_core/sdkconfiguration.py", "src/friendli/httpclient.py", "src/friendli/config.py", - "src/friendli_core/_version.py" + "src/friendli_core/__init__.py", + "src/friendli_core/endpoint.py", + "src/friendli_core/basesdk.py", + "src/friendli_core/httpclient.py", + "src/friendli_core/sdkconfiguration.py" ], "can_expand": true }, @@ -71,38 +71,25 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/chat.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/completions.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/dataset.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/image.py", "src/friendli/container/completions.py", "src/friendli/container/__init__.py", "src/friendli/container/chat.py", "src/friendli/container/token.py", - "src/friendli/serverless/completions.py", - "src/friendli/serverless/chat.py", - "src/friendli/serverless/tool_assisted_chat.py", - "src/friendli/serverless/token.py", - "src/friendli/serverless/knowledge.py", - "src/friendli/dedicated/completions.py", - "src/friendli/dedicated/chat.py", - "src/friendli/dedicated/image.py", - "src/friendli/dedicated/token.py", - "src/friendli/dedicated/audio.py", "src/friendli/dataset/__init__.py", "src/friendli/dataset/dataset.py", "src/friendli/file/__init__.py", "src/friendli/file/file.py", - "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli_core/completions.py", "src/friendli_core/file.py", "src/friendli_core/container.py", + "src/friendli_core/chat.py", "src/friendli_core/friendlicore_image.py", "src/friendli_core/friendlicore_completions.py", - "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/image.py", "src/friendli_core/toolassistedchat.py", + "src/friendli_core/dataset.py", "src/friendli_core/token.py", "src/friendli_core/friendlicore_token.py", - "src/friendli_core/friendlicore_serverless_completions.py", "src/friendli_core/friendlicore_chat.py", "src/friendli_core/knowledge.py", "src/friendli_core/audio.py" @@ -123,6 +110,7 @@ "assigned_files": [ "src/friendli/models.py", "src/friendli/types.py", + "src/friendli_core/model.py", "src/friendli_core/models/containerdetokenizationop.py", "src/friendli_core/models/splitinfo.py", "src/friendli_core/models/dedicatedgetendpointstatusop.py", @@ -213,7 +201,7 @@ "src/friendli_core/models/dedicatedgetendpointop.py", "src/friendli_core/models/list_versionsop.py", "src/friendli_core/models/completionsstreamdedicatedbodywithtokens.py", - "src/friendli_core/models/completionsstreamserverlessbodywithprompt.py", + "src/friendli_core/models/completionsstreamserverlessbodywithtokens.py", "src/friendli_core/models/streamedcompletionschoice.py", "src/friendli_core/models/get_versionop.py", "src/friendli_core/models/toolassistedchattool.py", @@ -356,13 +344,25 @@ } ], "assigned_files": [ - "/mnt/e/StartUp/friendli-python/src/friendli_core/dedicated.py", - "/mnt/e/StartUp/friendli-python/src/friendli_core/serverless.py", - "src/friendli_core/endpoint.py", + "src/friendli/serverless/completions.py", "src/friendli/serverless/__init__.py", + "src/friendli/serverless/chat.py", + "src/friendli/serverless/tool_assisted_chat.py", "src/friendli/serverless/model.py", + "src/friendli/serverless/token.py", + "src/friendli/serverless/knowledge.py", + "src/friendli/dedicated/completions.py", "src/friendli/dedicated/__init__.py", - "src/friendli/dedicated/endpoint.py" + "src/friendli/dedicated/chat.py", + "src/friendli/dedicated/endpoint.py", + "src/friendli/dedicated/image.py", + "src/friendli/dedicated/token.py", + "src/friendli/dedicated/audio.py", + "src/friendli_core/friendlicore_serverless_chat.py", + "src/friendli_core/dedicated.py", + "src/friendli_core/friendlicore_serverless_token.py", + "src/friendli_core/serverless.py", + "src/friendli_core/friendlicore_serverless_completions.py" ], "can_expand": true }, @@ -391,6 +391,7 @@ "referenced_source_code": [], "assigned_files": [ "src/friendli/utils.py", + "src/friendli_core/_version.py", "src/friendli_core/utils/metadata.py", "src/friendli_core/utils/__init__.py", "src/friendli_core/utils/forms.py", @@ -525,6 +526,13 @@ "assigned_files": [], "can_expand": false }, + { + "name": "Unclassified", + "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", + "referenced_source_code": [], + "assigned_files": [], + "can_expand": false + }, { "name": "Unclassified", "description": "Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies)", diff --git a/.codeboarding/codeboarding_version.json b/.codeboarding/codeboarding_version.json index 6efd86d..5794f67 100644 --- a/.codeboarding/codeboarding_version.json +++ b/.codeboarding/codeboarding_version.json @@ -1,4 +1,4 @@ { - "commit_hash": "6a93a3a37493a4fe3835b9f93030664d9f895966", + "commit_hash": "1def28d72026955db7b012597f0a488a89928ade", "code_boarding_version": "0.2.0" } diff --git a/.codeboarding/overview.md b/.codeboarding/overview.md index a5e72b9..1d62dc5 100644 --- a/.codeboarding/overview.md +++ b/.codeboarding/overview.md @@ -24,6 +24,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -207,6 +208,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_ diff --git a/docs/architecture/on_boarding.md b/docs/architecture/on_boarding.md index a75b277..b4fbc00 100644 --- a/docs/architecture/on_boarding.md +++ b/docs/architecture/on_boarding.md @@ -257,3 +257,11 @@ _Last updated: 2026-01-10 20:36:29 UTC_ - [overview.md](./overview.md) _Last updated: 2026-01-17 20:36:12 UTC_ +- [Data_Models_Error_Handling.md](./Data_Models_Error_Handling.md) +- [Friendli_Client_Public_API_.md](./Friendli_Client_Public_API_.md) +- [Platform_Abstractions.md](./Platform_Abstractions.md) +- [SDK_Core.md](./SDK_Core.md) +- [Service_Modules.md](./Service_Modules.md) +- [overview.md](./overview.md) + +_Last updated: 2026-01-24 20:36:21 UTC_ diff --git a/docs/architecture/overview.md b/docs/architecture/overview.md index a5e72b9..1d62dc5 100644 --- a/docs/architecture/overview.md +++ b/docs/architecture/overview.md @@ -24,6 +24,7 @@ graph LR Unclassified["Unclassified"] Unclassified["Unclassified"] Unclassified["Unclassified"] + Unclassified["Unclassified"] Friendli_Client_Public_API_ -- "delegates requests to" --> SDK_Core SDK_Core -- "utilizes" --> Data_Models_Error_Handling SDK_Core -- "adapts behavior based on" --> Platform_Abstractions @@ -207,6 +208,12 @@ Component for all unclassified files and utility functions (Utility functions/Ex Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) +**Related Classes/Methods**: _None_ + +### Unclassified +Component for all unclassified files and utility functions (Utility functions/External Libraries/Dependencies) + + **Related Classes/Methods**: _None_