Skip to content

Devika is the first open-source implementation of an Agentic Software Engineer. Initially started as an open-source alternative to Devin.

Python

Fix `AgentState` call for fetching the token usage

Mufeed VH6db23cba2f87
diff --git a/devika.py b/devika.py
index 5fe0930..c03350d 100644
--- a/devika.py
+++ b/devika.py
@@ -167,7 +167,7 @@ def calculate_tokens():
@route_logger(logger)
def token_usage():
project_name = request.args.get("project_name")
- token_count = AgentState().get_latest_token_usage(project_name)
+ token_count = AgentState.get_latest_token_usage(project_name)
return jsonify({"token_usage": token_count})