llama-index readers weather integration
Project description
Weather Loader
pip install llama-index-readers-weather
This loader fetches the weather data from the OpenWeatherMap's OneCall API, using the pyowm
Python package. You must initialize the loader with your OpenWeatherMap API token, and then pass in the names of the cities you want the weather data for.
OWM's One Call API provides the following weather data for any geographical coordinate: - Current weather - Hourly forecast for 48 hours - Daily forecast for 7 days
Usage
To use this loader, you need to pass in an array of city names (eg. [chennai, chicago]). Pass in the country codes as well for better accuracy.
from llama_index.readers.weather import WeatherReader
loader = WeatherReader(token="[YOUR_TOKEN]")
documents = loader.load_data(places=["Chennai, IN", "Dublin, IE"])
This loader is designed to be used as a way to load data into LlamaIndex.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file llama_index_readers_weather-0.2.0.tar.gz
.
File metadata
- Download URL: llama_index_readers_weather-0.2.0.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.10.13 Darwin/23.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9b811a575e2d707d88e6f7877601a3065a0a2804a126ab09192f428bcc519cc8 |
|
MD5 | 0813131081a618adde4d96a090c98ca3 |
|
BLAKE2b-256 | 35ac63deaf488efd621e0d9f768548ecb8b2ac69b4111af0c76d9664a0b5f998 |
File details
Details for the file llama_index_readers_weather-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: llama_index_readers_weather-0.2.0-py3-none-any.whl
- Upload date:
- Size: 3.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.10.13 Darwin/23.6.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7e80e4fda0c02cd6d9c1d2d39ad4c836181f5c9d576244a2a4185f67c8d77719 |
|
MD5 | 55d51e5df3d448d7fc2f646b5082265a |
|
BLAKE2b-256 | a1e27fb3e7025d26ddf8f27621e395846971ddfdfed5f22535d6e2a3982e6cba |