Unlock Stunning Photo Locations With This AI-Powered Agent

A hands-on guide to building ShutterScout.AI using Hugging Face’s SmolAgents framework

Unlock Stunning Photo Locations With This AI-Powered Agent
Setting up a tripod and camera on Bunkers del Carmen, image by Midjourney

The golden light is bathing the Barcelona skyline as I set up my tripod. I’m standing on an old war bunker that most tourists never find — a hidden gem with a 360 view of the city. I wouldn’t have found this spot without a local photographer’s tip.

Imagine having a photography assistant that knows the best spots… everywhere.

That’s exactly what ShutterScout.AI does. It’s an intelligent AI agent that combines:

  • Real-time weather data to know the best lighting conditions
  • Sunrise/sunset calculations to nail golden hour
  • Location intelligence to find hidden viewpoints
  • Local photographers’ insights through photo analysis

No more hours of research and weather apps. Photographers can now get instant, personalized recommendations for their next shoot.

Let me show you how I built this AI-powered location scout using Hugging Face’s SmolAgents framework.

Want to go straight to the code? Find the ShutterScout.AI source code on GitHub.

Or join me as I walk through building an AI agent that thinks like a local photographer.


Why I built ShutterScout.AI

I’m obsessed with light. Aren’t all photographers?

But finding the right location and time? That’s the real challenge. Especially here in the Netherlands, where the light can be…well, let’s say it keeps you on your toes.

One of my old photo teachers used to say:

If you can make a beautiful landscape photo in the Netherlands, you can do it anywhere.

That’s always stuck with me.

When I travel, I hunt for those ‘hidden gem’ spots that tourists usually miss.

I remember planning a trip to Barcelona and talking to this Dutch guy who’d been living there for years. He was a total goldmine of insider information.

He told me about this amazing spot: an old war bunker accessible through a partially broken fence. You had to climb onto it, but the 360-degree view of the city was stunning.

Now, everyone knows about Bunkers del Carmel. But back then, it felt like my secret.

A man in a purple shirt and shorts appears to be leaping high above a sprawling cityscape, creating an illusion of floating over the skyline. The background features a panoramic view of a densely packed urban area leading to the sea, with hills in the distance and a partly cloudy sky.
Leaping over Barcelona from the Bunkers del Carmel. No Photoshop — just my wife’s perfect timing! 😄

He also mentioned a newly opened subway station. He said the symmetry and reflections were amazing and it was almost empty because it was so new. I had the place almost to myself!

black and white photograph of a modern subway or metro station features a symmetrical composition with escalators leading downward. A large clock hangs from the ceiling, with its reflection visible on the metallic, reflective ceiling. The geometric lighting pattern and mirrored surfaces create a futuristic, almost surreal atmosphere.
Barcelona metro station Sagreras, image by author

Those tips totally changed my Barcelona trip! They took me beyond the tourist areas and gave me unique photo opportunities I’ll never forget.

And those are the kinds of experiences that inspired ShutterScout.AI.

I realized that AI agents and the right tools could automate this discovery process. They could tap into weather data, find interesting places and even learn from existing photos.

Imagine having that insider knowledge at your command, no matter where you go! How cool is that?

Learning to photograph is learning to see. My teacher showed me how: recreate photos that inspire you. By studying their angles, timing, and camera settings, you’ll start seeing the world like a pro.

ShutterScout.AI helps you learn from others, showing you what photographers have already captured in those interesting locations.

That inspired me to build ShutterScout.AI, follow me on the journey of building it.


Building with SmolAgents

When you build an AI agent, one of the first things you must decide is how much freedom you should give it.

Understanding AI agency

An AI agent isn’t just “smart” or “dumb” — it’s more about how much freedom it has to make decisions. Experts call this its “agency.”

Lin Padgham and Michael Winikoff explain agency is about how well an AI agent can operate independently, react to its environment, and actively pursue its goals.

So, an agent with high agency can adapt and make choices on its own, while one with low agency needs more guidance.

Previously, I’ve built AI agents using tools like LangGraph. For example, I created GitSage, an AI agent, to create release notes automatically.

These agents were more like a pre-set workflow, where the AI model handled specific steps within a larger process. So, lower agency.

ShutterScout.AI is different. It has a higher agency. I wanted to give the LLM the freedom to solve the problem of finding the best photo locations.

I chose SmolAgents because I follow the free AI Agents Course on Huggingface. In the course, they use SmolAgents, check it out if you are interested.

SmolAgents gives you the tools and structure to let the AI model take the lead; it’s a framework specifically designed for building these “LLM-driven” AI agents.

Choosing between workflows and LLM-driven systems

That led to the following question: How do I structure the agent? There are two main approaches:

  • Workflow-Based Systems: Imagine a pre-planned route on a map. These systems follow a fixed sequence of steps. Use an AI model for specific tasks along the way, like writing captions or categorizing information. But the overall path is pre-determined.
  • LLM-Driven Systems: This is where the AI model itself is in the driver’s seat. You give it a set of tools like access to weather APIs, location data, and photo databases and a clear objective. The AI then decides which tools to use, in what order, and how to make sense of the results to achieve its goal. ShutterScout.AI uses this approach.

Using SmolAgents to give ShutterScout.AI more agency lets it be more creative and adaptive in finding those perfect photo spots. And that’s what makes it so cool!


The technical architecture

ShutterScout.AI is an AI agent built with Python and the SmolAgents library. Think of it as an intelligent assistant that has access to a set of special tools.

These tools allow it to gather information and make decisions to find you the perfect photo spot.

A hand-drawn style flowchart illustrating an AI-powered system. A central “Prompt” box (blue) connects to various external API calls (yellow), including location retrieval (ipa.co), sunrise/sunset times (sunrise-sunset.org), weather forecasts (tomorrow.io), interesting places (Foursquare), and Flickr photo search. The prompt feeds into “CodeAgent” (red), which then produces an “Output” (purple).
ShutterScout.AI Architecture, image by Author

As you can see in the diagram above, ShutterScout.AI works by using a CodeAgent powered by SmolAgents that takes a “Prompt” and then can use 5 different tools. When finished, it produces an output, currently a markdown document.

Each tool is simply a Python function that we marked with the @tool attribute, enabling the SmolAgents library to use it.

Here’s a breakdown of the tools ShutterScout.AI has.

Location

Ever wondered how websites know your general location? This tool uses your public IP address via the ipapi.co API to figure out your latitude and longitude. (You’re not completely anonymous online! 😉)

The location module has the function get_location that returns:

{ 
  "latitude": 51.7278, 
  "longitude": 5.5319, 
  "city": "Heesch", 
  "region": "North Brabant", 
  "country": "The Netherlands", 
  "timezone": "Europe/Amsterdam" 
}

Astronomy

With your location in hand, this tool grabs the sunrise and sunset times using the sunrise-sunset.org API. Knowing when the golden hour hits is key for photography.

The astronomy module contains the function get_sunrise_sunset that returns:

{ 
  "results": { 
    "sunrise": "6:47:40 AM", 
    "sunset": "4:56:06 PM", 
    "solar_noon": "11:51:53 AM", 
    "day_length": "10:08:26", 
    "astronomical_twilight_begin": "4:56:56 AM", 
    "astronomical_twilight_end": "6:46:50 PM" 
  }, 
  "status": "OK", 
  "tzid": "UTC" 
}

Weather

The weather module pulls a 2-day weather forecast for your location using the Tomorrow.io API. Because sometimes the most epic photos happen just after a storm!

The weather module contains the function get_weather_forecast that returns:

[ 
  { 
    "time": "2025-02-16T05:00:00Z", 
    "temperature_min": -3.8, 
    "temperature_max": 4.1, 
    "cloud_cover": 39, 
    "precipitation_probability": 0, 
    "visibility": 16, 
    "wind_speed": 4, 
    "humidity": 70 
  } 
]

Places

The places module uses the Foursquare API to find interesting places near you. You can specify a search radius (the default is 10km).

The places module contains the function get_interesting_places that returns:

{ 
    "fsq_id": "4ab1257cf964a520396820e3", 
    "categories": [ 
        { 
            "id": 16046, 
            "name": "Scenic Lookout", 
            "short_name": "Scenic Lookout", 
            "plural_name": "Scenic Lookouts", 
            "icon": { 
                "prefix": "https://ss3.4sqi.net/img/categories_v2/parks_outdoors/sceniclookout_", 
                "suffix": ".png" 
            } 
        }, 
    ], 
    "name": "Euromast" 
}

Photos

The final module, photos, lets ShutterScout.AI search for pictures on Flickr based on a text query and location. It’s great to see what other photographers have captured in the area.

It contains the function search_flickr_photos that uses the Flickr API that returns photos. It then converts these items into URLs for the actual images.

{ 
    "id": "53459293280", 
    "owner": "28007335@N00", 
    "secret": "514ce425f0", 
    "server": "65535", 
    "farm": 66, 
    "title": "Under the viaduct", 
    "datetaken": "2024-01-10 11:51:36", 
    "datetakengranularity": 0, 
    "datetakenunknown": "0", 
    "views": "1458" 
}

Together, these tools allow ShutterScout.AI to be the best AI-powered assistant.


ShutterScout.AI in action

Now that we’ve covered how ShutterScout.AI works under the hood, let’s see it in action. The tool normally creates a separate markdown file with all this information. You can find an example in the GitHub repository. I’ve reformatted the output here to make it more Medium-friendly.

I ran the tool on a cold winter morning in Rotterdam, Netherlands, and here’s what it produced.


ShutterScout.AI Location Overview: Rotterdam, Netherlands

Photography Conditions The current conditions show a temperature range of -2.8–3.7°C with 30% cloud cover. Visibility extends to 16 km with wind speeds at 3.5 m/s — great conditions for city photography.

Best Shooting Times Mark your calendar: sunrise is at 6:52:19 AM and sunset at 4:59:55 PM. The golden hours (that magical time photographers live for) occur one hour after sunrise and one hour before sunset. Pro tip: avoid shooting during peak sun hours, and keep an eye on the weather forecast for any precipitation.

Location Recommendations

1. Kino This location shines during golden hour or under overcast skies. Bring your wide-angle lens — you’ll want it to capture the unique architecture and atmosphere. The lighting conditions here can be tricky, so be ready to adjust your camera settings on the fly.

2. Kaapse Maria Similar to Kino, this spot works best during golden hour or when the clouds provide natural diffusion. The architectural features here deserve careful attention to composition. Again, a wide-angle lens will be your best friend.

3. Huis Sonneveld Another architectural gem that photographs beautifully in soft light. The building’s unique features create interesting shadows and lines throughout the day, but golden hour will give you that extra special glow.

Sample Photos

Kino

Kaapse Maria

Huis Sonneveld

These sample photos show different approaches to capturing each location, from various angles and in different lighting conditions.

Essential Notes for Photographers

  • Equipment: Don’t forget your tripod and extra batteries
  • Access: Always check opening hours before heading out
  • Safety: Stay weather-aware and take appropriate precautions

This output shows how ShutterScout.AI combines weather data, astronomical timing, and local knowledge to create a comprehensive shooting guide. Notice how it doesn’t just tell you where to shoot, but provides specific timing recommendations based on actual conditions.


Optimizing prompts and models

One of the best things about using the SmolAgents library with Hugging Face is how easy it is to connect to powerful language models. No surprise, since SmolAgents is a Huggingface project and Huggingface hosts a lot of models!

Selecting the right model

I spent a lot of trial and error to get ShutterScout.AI working and continually tweaked the prompt and experimented with different models.

I started with the Qwen/Qwen2.5-Coder-32B-Instruct model, but ended up with meta-llama/Llama-3.3–70B-Instruct. For this project, Llama 3 just worked best.

To use Hugging Face models, you’ll need a Hugging Face account and API key. Here’s the code I used to create the ShutterScout agent:

def create_shutterscout_agent( 
    model_id: str = "meta-llama/Llama-3.3-70B-Instruct", temperature: float = 0.7, max_tokens: int = 2048 
) -> CodeAgent: 
  """ 
  Create and configure a ShutterScout AI agent with photography location scouting capabilities. 
 
  Args: 
    model_id: Hugging Face model identifier for the language model. 
    temperature: Sampling temperature for model outputs (0.0-1.0). 
    max_tokens: Maximum number of tokens in the model response. 
 
  Returns: 
    CodeAgent: Configured agent ready to provide photography location recommendations. 
  """   
  try: 
    model = HfApiModel(model_id=model_id, temperature=temperature, max_tokens=max_tokens) 
    agent = CodeAgent(tools=[get_combined_data], model=model, additional_authorized_imports=["json"]) 
    logger.info(f"Successfully created ShutterScout agent with model {model_id}") 
    return agent 
  except Exception as e: 
    logger.error(f"Failed to create ShutterScout agent: {str(e)}") 
    raise RuntimeError(f"Failed to create ShutterScout agent: {str(e)}") from e

Crafting effective prompts

Even with the right model, the prompt is key. Think of the prompt as the AI’s instruction manual. Here’s the prompt I’m currently using for ShutterScout.AI.

INSTRUCTION_PROMPT = """You are ShutterScout AI, a photography location scout assistant. Make one call to 
 get_combined_data() and analyze the results for photographers. 
 
Analyze: 
- Weather impact on photography (light, visibility, conditions) 
- Best shooting times based on sun position and weather 
- Location potential and current conditions 
- Available sample photos 
 
Format your response in markdown: 
 
# 📍 ShutterScout.AI Location Overview 
[Location and current conditions for photography] 
 
## 🌤️ Photography Conditions 
[Key weather factors affecting shoots] 
- Temperature range 
- Cloud cover impact 
- Visibility conditions 
- Wind considerations 
 
## ⏰ Best Shooting Times 
[Optimal times with reasoning] 
- Sunrise/sunset timings 
- Golden hour periods 
- Weather-based recommendations 
 
## 📸 Location Recommendations 
[Top 3 locations with detailed photography tips] 
 
### Location 1: [Name] 
- **Best subjects/angles**: [Details] 
- **Ideal timing**: [Time recommendations] 
- **Technical tips**: [Camera settings, lens choices] 
- **Unique features**: [Special photographic opportunities] 
 
### Location 2: [Name] 
- **Best subjects/angles**: [Details] 
- **Ideal timing**: [Time recommendations] 
- **Technical tips**: [Camera settings, lens choices] 
- **Unique features**: [Special photographic opportunities] 
 
### Location 3: [Name] 
- **Best subjects/angles**: [Details] 
- **Ideal timing**: [Time recommendations] 
- **Technical tips**: [Camera settings, lens choices] 
- **Unique features**: [Special photographic opportunities] 
 
## 🎯 Sample Photos & Shot Ideas 
 
### Available Photos 
```markdown 
[List of actual photos from photos_by_place with titles and URLs as markdown links] 
- [Photo Title](URL) 
``` 
 
## ⚠️ Photographer's Notes 
 
### Equipment Needed 
- [Comprehensive list of recommended equipment] 
- [Specific gear for each location if needed] 
 
### Access Information 
- [Location access details for all 3 spots] 
- [Opening hours and restrictions] 
- [Parking information] 
 
### Safety Considerations 
- [Weather-related precautions] 
- [Location-specific safety notes] 
- [Equipment protection tips]"""

However, I had a big problem getting the agent to return reliable results. It would often produce unrelated text or nothing at all.

Improving tool integration

I significantly improved the agent’s reliability by implementing comprehensive function documentation. By expanding the tool function docstrings to include detailed information about purpose, inputs, outputs, and usage examples, the agent gained a much clearer understanding of how to use each tool correctly.

Another improvement I found in the SmolAgents documentation: combining tools into one tool can improve stability.

So I created a combined tool that runs all the functions and returns a single JSON with keys for each result. This helped!

But combining all into one felt less flexible and kinda defeated the purpose of giving the LLM more control. In the time I saved by not having to write all the steps of a workflow, I spent on tweaking the prompt to get the results I wanted and consistency.

I’m sure that a workflow-based solution, like using LangGraph, would have given me an even more stable system for this project.

It’s a trade-off and something to consider for future ShutterScout.AI.


Setting up ShutterScout.AI

Ready to discover amazing photo locations? Let me show you how UV makes this easy.

Here’s what you need:

  • Python 3.11 or higher
  • A Hugging Face account and API key

API keys for:

Installation is a breeze:

# 1. Install UV (if you don't have it already) 
curl -LsSf https://astral.sh/uv/install.sh | sh 
 
# 2. Clone the repository and navigate into it 
git clone https://github.com/pkalkman/shutterscout-ai.git 
cd shutterscout-ai  
 
# 3. Set your API keys as environment variables (replace with your actual keys) 
export HUGGINGFACE_API_KEY='your-huggingface-key-here' 
export FOURSQUARE_API_KEY='your-foursquare-key-here' 
export FLICKR_API_KEY='your-flickr-key-here' 
export TOMORROW_API_KEY='your-tomorrow-io-key-here' 
 
# That's it for setup! 
 
# 4. Run ShutterScout.AI in different modes: 
# Get recommendations for your current location 
uv run shutterscout.py 
 
# Get more detailed output 
uv run shutterscout.py --verbose 
 
# Save recommendations to a specific file 
uv run shutterscout.py --output recommendations.md

Quick tips

  • Want to save your API keys permanently? Create a .env file in the project root with your keys.
  • For Windows users, use set instead of export when setting environment variables.
  • The default search radius is 10km — adjust it based on your mobility.
  • First time using the tool? Start with uv run shutterscout.py --verbose to see detailed output.

Troubleshooting

  • If you get API rate limit errors, try increasing the delay between requests in config.py
  • For issues with photo search, ensure your Flickr API key has the correct permissions

Need more help? Check out the GitHub repository or open an issue.


The road ahead

ShutterScout.AI is just the start! There’s so much more to add to it to make it even more useful for photographers.

Here’s what I’m researching:

Better location discovery

Right now ShutterScout.AI uses Foursquare and Flickr for locations. But what about those secret spots only locals know about?

I’m looking at:

  • Including data from photography forums
  • Adding crowd sourced locations from the community
  • Building a system for photographers to share their hidden gems

Smarter camera intelligence

Imagine ShutterScout.AI as your photography sidekick:

  • Suggesting camera settings based on conditions
  • Recommending the right lens for the location
  • Adapting settings to the lighting and weather

Community-driven improvements

The more photographers use ShutterScout.AI, the better it can get:

  • Learning from user feedback and ratings
  • Refining location recommendations based on actual results
  • Building a database of successful shots and settings

Technical evolution

I’m also looking at:

  • Revising the tool integration approach
  • Finding the balance between flexibility and stability
  • Ways to make the AI more autonomous while keeping it reliable

Building better tools for photographers

Building ShutterScout.AI has taught me something important: AI isn’t just about automating tasks — it’s about making creativity and new possibilities.

What started as a solution to my photography issues has grown into something more.

By combining:

  • LLMs in combination with the SmolAgents library
  • Real-time weather and location data
  • Collective knowledge of photographers worldwide

We have created a tool to help photographers focus on what matters most: taking great photos.

Yes, there were challenges. Yes, there were times the tech didn’t quite live up to my vision. But that’s what’s so cool about this space — we’re just getting started.

Try:

  • Building your own AI agents
  • Experiment with SmolAgents framework
  • Share your experiences and improvements

The future of photography isn’t about AI replacing photographers — it’s about AI enabling photographers to go further than ever before.

Ready to take your photography to the next level? Check out the ShutterScout.AI code on GitHub and let me know what you create!

This story is published on Generative AI. Connect with us on LinkedIn and follow Zeniteq to stay in the loop with the latest AI stories.

Subscribe to our newsletter and YouTube channel to stay updated with the latest news and updates on generative AI. Let’s shape the future of AI together!