Pollinations.AI — MIT License
=============================

Upstream project: https://github.com/pollinations/pollinations
Website:          https://pollinations.ai

Role in this mod:
  The Minecraft mod "Intelligent Villagers" integrates Pollinations.AI as
  its free, anonymous cloud fallback for four distinct feature paths.
  All four run strictly client-side (on the player's own PC); the mod's
  Minecraft dedicated server NEVER reaches Pollinations. Each path is
  gated behind its own explicit opt-in flag in CloudFallbackConfig
  (text / tts / stt) that the player must enable in the 3-card setup
  screens or the title-screen cloud toggle.

  1. IMAGE GENERATION
       Endpoint: GET https://image.pollinations.ai/prompt/<urlenc>?model=flux
       Caller:   ImageGenClient.text2image
       Model:    FLUX.1-schnell (see FLUX_APACHE-2.0.txt)
       Opt-in:   always available — player triggers via the in-game
                 Artist NPC painting flow or Profile-Image Studio.

  2. TEXT / LLM CHAT (fallback when local Ollama is missing)
       Endpoint: POST https://text.pollinations.ai/openai
                 (OpenAI Chat-Completions-compatible body)
       Caller:   CloudAIFallbackClient.chatSingle
       Model:    openai-fast = GPT-OSS 20B Reasoning (hosted on OVH
                 infrastructure by Pollinations). Apache 2.0
                 (© 2025 OpenAI — https://huggingface.co/openai/gpt-oss-20b).
       Opt-in:   CloudFallbackConfig.isTextEnabled().

  3. TEXT-TO-SPEECH (fallback when local Piper is missing)
       Endpoint: GET https://text.pollinations.ai/<urlenc-text>
                    ?model=openai-audio&voice=<alloy|echo|fable|onyx|nova|shimmer>
       Caller:   CloudAIFallbackClient.tts
       Model:    OpenAI's six base voices, brokered through the
                 Pollinations gateway. The mod does not hold a direct
                 OpenAI licence; synthesised audio bytes returned to the
                 player are user-owned output.
       Opt-in:   CloudFallbackConfig.isTtsEnabled().

  4. SPEECH-TO-TEXT (fallback when local whisper.cpp is missing)
       Endpoint: POST https://text.pollinations.ai/openai/v1/audio/transcriptions
                 (OpenAI-Whisper-compatible multipart/form-data with a
                 WAV file + optional language code)
       Caller:   CloudAIFallbackClient.stt
       Model:    Whisper-1 (MIT, © 2022-2023 OpenAI).
       Opt-in:   CloudFallbackConfig.isSttEnabled().

  The mod DOES NOT vendor / embed / redistribute any Pollinations source
  code — it consumes the public HTTP API. The MIT attribution + license-
  text requirement below is satisfied by including this file in the
  distribution, even though the strict letter of the MIT License is
  only triggered when source code is redistributed.

---------------------------------------------------------------------

MIT License

Copyright (c) 2023 pollinations

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

---------------------------------------------------------------------

Pollinations Usage Notes (non-license, operational):
  • Anonymous rate-limit: 1 request / 15 s per IP. Applies to all four
    endpoint paths (image / text / tts / stt) — they share one budget.
    Matches the mod's internal per-player cooldown.
  • `private=true` (image only): the generated image does not appear on
    Pollinations' public feed. Always sent by ImageGenClient.
  • `nologo=true` (image only): suppresses the Pollinations watermark.
    Since March 31 2025, Pollinations may still apply a watermark on the
    anonymous / free tier regardless of this flag — registration at
    https://auth.pollinations.ai is required for guaranteed watermark-
    free output. The mod still sends the flag so registered-account
    paths benefit.
  • For the three text-based endpoints (text / tts / stt) there is no
    watermark policy — transcripts, chat replies and audio buffers are
    returned as raw user-owned bytes.
  • Server outage handling: on any non-200 HTTP response, the mod's
    Cloud-Fallback client returns an empty result. Callers already
    gracefully degrade (NPC falls silent instead of crashing).
  • Commercial use: Pollinations' MIT licence permits both commercial
    and non-commercial use of the platform. The licence of the returned
    content is governed by each model's licence:
        - Images (FLUX)          → Apache 2.0  (user-owned output)
        - Text (GPT-OSS 20B)     → Apache 2.0  (user-owned output)
        - Audio (OpenAI voices)  → user-owned output; voices remain
                                   OpenAI's service (no direct licence)
        - Transcripts (Whisper)  → MIT         (user-owned output)
    In every path the generated content itself is free for commercial
    use by the player who produced it.
