Skip to content

Commit

Permalink
Fix extra Anthropic import error.
Browse files Browse the repository at this point in the history
  • Loading branch information
eli64s committed Oct 7, 2024
1 parent 8f06183 commit 2337e4b
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "readmeai"
version = "0.5.90"
version = "0.5.91"
description = "Automated README file generator, powered by AI."
authors = ["Eli <egsalamie@gmail.com>"]
license = "MIT"
Expand Down
1 change: 0 additions & 1 deletion readmeai/models/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
"""Initialize the llms module."""
9 changes: 9 additions & 0 deletions readmeai/models/anthropic.py → readmeai/models/claude.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Anthropic API service implementation."""

import logging
from typing import Any

import anthropic
Expand All @@ -15,6 +16,14 @@
from readmeai.models.base import BaseModelHandler
from readmeai.models.tokens import token_handler

_logger = logging.getLogger(__name__)

try:
import anthropic
except ImportError:
_logger.warning("Anthropic API not found, please install 'anthropic'.")
anthropic = None


class AnthropicHandler(BaseModelHandler):
"""
Expand Down
File renamed without changes.

0 comments on commit 2337e4b

Please sign in to comment.