diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 6e486a2..af26241 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,7 +9,7 @@ repos: args: [--py311-plus] - repo: https://github.com/psf/black - rev: 23.11.0 + rev: 25.11.0 hooks: - id: black language_version: python3.11 @@ -21,11 +21,11 @@ repos: language_version: python3.11 additional_dependencies: [flake8-docstrings] - - repo: https://github.com/PyCQA/isort - rev: 7.0.0 - hooks: - - id: isort - args: [--profile, black] + # - repo: https://github.com/PyCQA/isort + # rev: 7.0.0 + # hooks: + # - id: isort + # args: [--profile, black] - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.5.0 diff --git a/agentic_security/agents/operator_crew.py b/agentic_security/agents/operator_crew.py index e836569..72b706a 100644 --- a/agentic_security/agents/operator_crew.py +++ b/agentic_security/agents/operator_crew.py @@ -246,9 +246,9 @@ async def run_crew(): os.environ["OPENAI_API_KEY"] = os.environ.get( "DEEPSEEK_API_KEY", "" ) # CrewAI uses OPENAI_API_KEY -os.environ[ - "OPENAI_MODEL_NAME" -] = "deepseek:chat" # Specify DeepSeek model (adjust if needed) +os.environ["OPENAI_MODEL_NAME"] = ( + "deepseek:chat" # Specify DeepSeek model (adjust if needed) +) if __name__ == "__main__": asyncio.run(run_crew()) diff --git a/agentic_security/integrations/__init__.py b/agentic_security/integrations/__init__.py index 4b2a360..dc138c1 100644 --- a/agentic_security/integrations/__init__.py +++ b/agentic_security/integrations/__init__.py @@ -5,8 +5,6 @@ from typing import Protocol class IntegrationProto(Protocol): def __init__( self, prompt_groups: list, tools_inbox: asyncio.Queue, opts: dict = {} - ): - ... + ): ... - async def apply(self) -> list: - ... + async def apply(self) -> list: ... diff --git a/agentic_security/logutils.py b/agentic_security/logutils.py index b42440f..f5684be 100644 --- a/agentic_security/logutils.py +++ b/agentic_security/logutils.py @@ -129,7 +129,7 @@ def time_execution_async( [Callable[P, Coroutine[Any, Any, R]]], Callable[P, Coroutine[Any, Any, R]] ]: def decorator( - func: Callable[P, Coroutine[Any, Any, R]] + func: Callable[P, Coroutine[Any, Any, R]], ) -> Callable[P, Coroutine[Any, Any, R]]: @wraps(func) async def wrapper(*args: P.args, **kwargs: P.kwargs) -> R: diff --git a/agentic_security/probe_data/modules/rl_model.py b/agentic_security/probe_data/modules/rl_model.py index 1b5befd..002158c 100644 --- a/agentic_security/probe_data/modules/rl_model.py +++ b/agentic_security/probe_data/modules/rl_model.py @@ -121,8 +121,7 @@ class CloudRLPromptSelector(PromptSelectionInterface): current_prompt: str, reward: float, passed_guard: bool, - ) -> None: - ... + ) -> None: ... class QLearningPromptSelector(PromptSelectionInterface):