Skip to contents

artgemini 0.2.0

Breaking Changes - API Consolidation

  • Artwork analysis functions removed - The following functions have been removed from artgemini:

    • art_about_ai() → Use artcurator::art_about_ai() instead
    • art_style_ai() → Use artcurator::art_style_ai() instead
    • classify_styles_ai() → Use artcurator::classify_styles_ai() instead
    • art_profile_ai() → Use artcurator::art_profile_ai() instead
    • art_profile_full_ai() → Use artcurator::art_profile_full_ai() instead

    Rationale: artcurator now provides a unified interface for artwork analysis with provider abstraction (switch between Gemini/OpenAI). All artwork-specific prompts and high-level functions have been consolidated there.

  • Removed internal utilities (now provided by artcore):

    • Removed b64EncodeImage() from R/internal-utils.R → Use artcore::b64EncodeImage()
    • Removed %||% operator definition → Imported from artcore
    • Removed R/internal-utils.R file entirely

New Exports - Low-Level API

  • Exported gemini_generate() - Previously internal .gemini_generate() is now exported for use by artcurator and other packages
    • Provides low-level access to Gemini generateContent API
    • Supports full parameter control: contents, instruction, temp, resp_fmt, cache, etc.
    • Use for custom prompts and advanced workflows

Dependencies

  • Added to Imports: artcore (>= 1.4.0) - Provides shared HTTP, config, and image utilities
  • Removed from Imports: base64enc, magick - Now provided by artcore dependency
  • Dependencies alphabetized for consistency

Migration Guide

For artpipelines and Other Consumers

Replace direct artgemini function calls with artcurator:

# Before
artgemini::art_about_ai(img_path)
artgemini::art_style_ai(img_path)

# After
artcurator::art_about_ai(img_path, provider = "gemini")
artcurator::art_style_ai(img_path, provider = "gemini")

See vignette("artpipelines-integration", package = "artcurator") for complete migration guide.

Low-Level API Remains Available

For custom prompts and advanced use cases, use the exported low-level functions:

# Low-level API (NOT deprecated)
artgemini::gemini_chat()
artgemini::gemini_generate()
artgemini::gemini_with_tools()
artgemini::gemini_continue()
artgemini::gemini_cache_*()