Gemini Thinking Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
GEMINI_API_KEYYesYour Google Gemini API key

Schema

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Tools

Functions exposed to the LLM to take actions

NameDescription
geminithinking

A detailed tool for dynamic and reflective problem-solving through Gemini AI. This tool helps analyze problems through a flexible thinking process powered by Google's Gemini model. Each thought can build on, question, or revise previous insights as understanding deepens.

When to use this tool:

  • Breaking down complex problems into steps
  • Planning and design with room for revision
  • Analysis that might need course correction
  • Problems where the full scope might not be clear initially
  • Problems that require a multi-step solution
  • Tasks that need to maintain context over multiple steps
  • Situations where irrelevant information needs to be filtered out

Key features:

  • Leverages Gemini AI for deep analytical thinking
  • Provides meta-commentary on the reasoning process
  • Indicates confidence levels for generated thoughts
  • Suggests alternative approaches when relevant
  • You can adjust total_thoughts up or down as you progress
  • You can question or revise previous thoughts
  • You can add more thoughts even after reaching what seemed like the end
  • You can express uncertainty and explore alternative approaches
  • Not every thought needs to build linearly - you can branch or backtrack
  • Session persistence: save and resume your analysis sessions

Parameters explained:

  • query: The question or problem to be analyzed
  • context: Additional context information (e.g., code snippets, background)
  • approach: Suggested approach to the problem (optional)
  • previousThoughts: Array of previous thoughts for context
  • thought: The current thinking step (if empty, will be generated by Gemini)
  • next_thought_needed: True if you need more thinking, even if at what seemed like the end
  • thought_number: Current number in sequence (can go beyond initial total if needed)
  • total_thoughts: Current estimate of thoughts needed (can be adjusted up/down)
  • is_revision: A boolean indicating if this thought revises previous thinking
  • revises_thought: If is_revision is true, which thought number is being reconsidered
  • branch_from_thought: If branching, which thought number is the branching point
  • branch_id: Identifier for the current branch (if any)
  • needs_more_thoughts: If reaching end but realizing more thoughts needed
  • metaComments: Meta-commentary from Gemini about its reasoning process
  • confidenceLevel: Gemini's confidence in the generated thought (0-1)
  • alternativePaths: Alternative approaches suggested by Gemini

Session commands:

  • sessionCommand: Command to manage sessions ('save', 'load', 'getState')
  • sessionPath: Path to save or load the session file (required for 'save' and 'load' commands)

You should:

  1. Start with a clear query and any relevant context
  2. Let Gemini generate thoughts by not providing the 'thought' parameter
  3. Review the generated thoughts and meta-commentary
  4. Feel free to revise or branch thoughts as needed
  5. Consider alternative paths suggested by Gemini
  6. Only set next_thought_needed to false when truly done
  7. Use session commands to save your progress and resume later