Skip to main content

Osmmap Loader

pip install llama-index-readers-maps

The Osmmap Loader will fetch map data from the Overpass api for a certain place or area. Version Overpass API 0.7.60 is used by this loader.

The api will provide you with all the nodes, relations, and ways for the particular region when you request data for a region or location.

Functions of the loader

  • To start, it first filters out those nodes that are already tagged, leaving just those nodes that are within 2 kilometres of the target location. The following keys are removed during filtering:["nodes," "geometry," "members"] from each node. The response we received is based on the tags and values we provided, so be sure to do that. The actions are covered below.

Steps to find the suitable tag and values

  1. Visit Taginfo. In essence, this website has all conceivable tags and values.
  2. Perform a search for the feature you're looking for, for instance, "hospital" will return three results: "hospital" as an amenity, "hospital" as a structure, and "hospital" as a healthcare facility.
  3. We may infer from the outcome that tag=amenity and value=hospital.
  4. Leave the values parameter to their default value if you do not need to filter.

Usage

The use case is here.

Let's meet Jayasree, who is extracting map features from her neighbourhood using the OSM map loader. She requires all the nodes, routes, and relations within a five-kilometer radius of her locale (Guduvanchery).

  • She must use the following arguments in order to accomplish the aforementioned. Localarea = "Guduvanchery" (the location she wants to seek), local_area_buffer = 5000 (5 km).

And the code snippet looks like

from llama_index.readers.maps import OpenMap

loader = MapReader()
documents = loader.load_data(
    localarea="Guduvanchery",
    search_tag="",
    tag_only=True,
    local_area_buffer=5000,
    tag_values=[""],
)

Now she wants only the list hospitals around the location

  • so she search for hospital tag in the Taginfo and she got
from llama_index.readers.maps import OpenMap

loader = MapReader()
documents = loader.load_data(
    localarea="Guduvanchery",
    search_tag="amenity",
    tag_only=True,
    local_area_buffer=5000,
    tag_values=["hospital", "clinic"],
)

This loader is designed to be used as a way to load data into LlamaIndex.

Metadata

Release files for llama-index-readers-maps 0.7.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llama-index-readers-maps 0.7.0
File Size Uploaded Provenance Actions
llama_index_readers_maps-0.7.0.tar.gz 5.6 kB Without provenance Details for llama_index_readers_maps-0.7.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for llama-index-readers-maps 0.7.0
File Interpreter ABI Platform Actions
llama_index_readers_maps-0.7.0-py3-none-any.whl Python 3 none any Details for llama_index_readers_maps-0.7.0-py3-none-any.whl

Total release size: 10.7 kB

Release files / llama_index_readers_maps-0.7.0.tar.gz

Download URL llama_index_readers_maps-0.7.0.tar.gz
Size 5.6 kB
Tags Source
SHA-256 checksum
How to use checksums
9d295950ded23ba860dc9c6e1b62934ad6f70800c92cd543ff096e7aeb1de561
BLAKE2b-256 checksum
How to use checksums
b921b43b680bd61f8c7c649535c07974b28cede04e7f1432b9c5be9db04d7727
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / llama_index_readers_maps-0.7.0-py3-none-any.whl

Download URL llama_index_readers_maps-0.7.0-py3-none-any.whl
Size 5.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9f124bd7b8304a488774a4fb3d0c66241160d02c500f70d1361359685fbc3792
BLAKE2b-256 checksum
How to use checksums
73aa7cbd0cff40cc463ad17b978ac296f51be7920da94a93b93f8b24c150568d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for llama-index-readers-maps 0.7.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page