Loopstructural logo

Loopstructural

Community
SteadfastAsArt
loopstructural

Build 3D geological models with implicit surfaces, faults, folds, and stratigraphic constraints from structural geology data. Use when the agent needs to: (1) Build 3D geological models from structural data, (2) Model fault networks and displacements, (3) Create folded geology representations, (4) Interpolate geological surfaces, (5) Export models to VTK for visualization, (6) Perform uncertainty analysis on geological models, (7) Evaluate model values on grids.

Overview

PublisherSteadfastAsArt
Repositorygeoscience-skills
Skill nameloopstructural
Stars
75
Forks
9
Bundled files
3
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 3 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by SteadfastAsArt on GitHub. Read the source before you install it.

Installation

Install the Loopstructural AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/SteadfastAsArt/geoscience-skills/tree/main/loopstructural
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/SteadfastAsArt/geoscience-skills.git /tmp/geoscience-skills
mkdir -p .claude/skills
cp -r /tmp/geoscience-skills/loopstructural .claude/skills/loopstructural
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Loopstructural in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Loopstructural on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Loopstructural is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Constrained implicit geological models

Use LoopStructural when observations constrain continuous geological scalar fields. A scalar value labels an interface; it is not automatically an age, measured depth or elevation. Record the coordinate CRS, shared XYZ units, positive-Z convention, feature order and meaning of each scalar level.

A constrained planar model

This synthetic example uses metre coordinates with a nonzero origin and an asymmetric box. Its scalar field is Z - 3030 + 0.1*(X - 1050) - 0.05*(Y - 2100) in metres. Scalar observations and gradient constraints anchor both level and orientation; a single point alone cannot define a geological surface.

python
from itertools import product
from LoopStructural import GeologicalModel
import numpy as np
import pandas as pd

origin = np.array([1000., 2000., 3000.])
maximum = np.array([1100., 2200., 3060.])
xyz = np.array(list(product([1010., 1050., 1090.], [2020., 2180.], [3010., 3050.])))
data = pd.DataFrame(xyz, columns=['X', 'Y', 'Z'])
data['feature_name'] = 'strat'
data['val'] = xyz[:, 2] - 3030 + .1 * (xyz[:, 0] - 1050) - .05 * (xyz[:, 1] - 2100)
data[['gx', 'gy', 'gz']] = [.1, -.05, 1.]
model = GeologicalModel(origin, maximum)
model.data = data
model.create_and_add_foliation('strat', interpolatortype='FDI', nelements=1000)
model.update()
query = np.array([[1020., 2040., 3020.], [1080., 2160., 3040.], [1050., 2100., 3030.]])
values = model.evaluate_feature_value('strat', query)

The expected values are approximately −10, +10 and 0. Pass world coordinates to model.evaluate_feature_value(..., scale=True) (the default). Direct feature evaluation has a different local-coordinate contract. GeologicalModel 1.8 accepts the two bounds positionally; do not assume origin= and maximum= constructor keywords from older examples still work.

Evaluate a VTK grid

Continue with the model above. regular_grid returns an N×3 array; disable shuffling and use Fortran ordering for VTK's x-fastest points. Write actual scalar values into point data before saving.

python
import pyvista as pv

shape = (9, 7, 5)
points = model.regular_grid(nsteps=shape, shuffle=False, order='F')
grid = pv.StructuredGrid()
grid.points = points
grid.dimensions = shape
grid.point_data['strat'] = model.evaluate_feature_value('strat', points)
surface = grid.contour([0.], scalars='strat')
if not np.isfinite(grid['strat']).all() or surface.n_cells == 0:
    raise ValueError('Model evaluation or requested isosurface is invalid')

Use grid.save('model.vtk') or surface.save('strat.vtk') when export is requested. A rendered surface is a discretized level set; check constraint residuals and mesh convergence before interpreting small structures.

CSV helper and conditional models

The model builder supports constrained FDI/PLI foliations and grid/isosurface export. It validates finite coordinates, complete constraints and positive 3D extents, and reports failed or empty exports with a nonzero exit status. Provide explicit bounds for planar or zero-span input geometry rather than inventing an extent.

bash
python scripts/build_model.py constraints.csv --grid --output model.vtk \
  --origin 1000 2000 3000 --maximum 1100 2200 3060 --nsteps 9 7 5

Resolve the command relative to this installed skill directory. The helper requires X,Y,Z,feature_name, plus val and/or complete gx,gy,gz or nx,ny,nz constraints; each feature needs a scalar level anchor. Missing vector rows are all NaN, not zero vectors.

Read interpolation and validation for numerical choices, and fault/fold requirements only when those structures are needed. Faults, fold frames and uncertainty ensembles need explicit kinematics/data and a separate configured model; they are not created by a nominal CSV column or by this foliation helper.

Verification scope

LoopStructural 1.8.0 with loop-interpolation 0.0.2 was exercised with FDI and PLI planar models, world-coordinate evaluation, asymmetric grid ordering, isosurface and VTK readback, plus malformed-input/CLI failures. This validates the entrypoint and export path, not fault-network inversion, folded geology, uncertainty estimates or the geological adequacy of sparse field constraints.

Official model source, checked 2026-09-14 against the installed 1.8.0 API.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Loopstructural AI skill do?

Build 3D geological models with implicit surfaces, faults, folds, and stratigraphic constraints from structural geology data. Use when the agent needs to: (1) Build 3D geological models from structural data, (2) Model fault networks and displacements, (3) Create folded geology representations, (4) Interpolate geological surfaces, (5) Export models to VTK for visualization, (6) Perform uncertainty analysis on geological models, (7) Evaluate model values on grids.

Why use Loopstructural on TypingMind?

Because you install it once and use it with any model. Loopstructural is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Loopstructural in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/SteadfastAsArt/geoscience-skills/tree/main/loopstructural. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Loopstructural?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Loopstructural?

As many as you like. As long as a model supports skills, you can use Loopstructural with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Loopstructural AI skill free?

Yes. It is published on GitHub by SteadfastAsArt under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇