Skip to content

Latest commit

 

History

History
74 lines (43 loc) · 4.39 KB

File metadata and controls

74 lines (43 loc) · 4.39 KB
graph LR
    create_app["create_app"]
    register_routes["register_routes"]
    submit_scan_prompt["submit_scan_prompt"]
    submit_scan_output["submit_scan_output"]
    submit_analyze_prompt["submit_analyze_prompt"]
    create_app -- "initiates" --> register_routes
    register_routes -- "maps requests to" --> submit_scan_prompt
    register_routes -- "maps requests to" --> submit_scan_output
    register_routes -- "maps requests to" --> submit_analyze_prompt
Loading

CodeBoardingDemoContact

Details

The API Gateway subsystem serves as the primary external interface for the LLM Guard system, handling all incoming scan and analysis requests.

create_app

Initializes the FastAPI application, orchestrates the setup of scanners, and registers all API routes. It serves as the main entry point for the API.

Related Classes/Methods:

register_routes

Defines and registers the various API endpoints (e.g., /scan/prompt, /scan/output, /analyze/prompt) with their respective handler functions. It also integrates authentication mechanisms.

Related Classes/Methods:

submit_scan_prompt

Serves as the API endpoint handler for receiving and processing requests to scan user prompts. It delegates the actual scanning to the core scanner engine.

Related Classes/Methods:

submit_scan_output

Serves as the API endpoint handler for receiving and processing requests to scan LLM-generated outputs. It delegates the actual scanning to the core scanner engine.

Related Classes/Methods:

submit_analyze_prompt

Serves as the API endpoint handler for requests related to prompt analysis.

Related Classes/Methods: