agentsclimarketplace

Restful api endpoint invocation

Skill HolobiomicsLab/asb-skill-collections/packs/metabolomics/nmr/skills/restful-api-endpoint-invocation

Curated, evidence-grounded skill and software-tool collections for scientific AI agents, generated by the AgenticScienceBuilder

Install
npx -y skills add HolobiomicsLab/asb-skill-collections --skill restful-api-endpoint-invocation

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 14 stars14 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Use when you have NMR peak data (1H and 13C chemical shift values) and need to obtain SMART 3 classification predictions from the DeepSAT service.

The file declares its own license as CC-BY-4.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

5.3 KB, as published. Nobody here has run it

RESTful API endpoint invocation

Summary

Submit structured peak data (chemical shifts) to a remote classification API endpoint and parse the returned predictions and confidence scores. This skill enables programmatic access to machine-learning-based spectral classification without local model deployment.

When to use

You have NMR peak data (1H and 13C chemical shift values) and need to obtain SMART 3 classification predictions from the DeepSAT service. Use this skill when you want to avoid local TensorFlow model management and instead leverage a deployed API endpoint that handles versioning and model updates transparently.

When NOT to use

  • Input peaks are not in 1H and 13C format or lack required chemical shift headers
  • The DeepSAT API endpoint is unavailable or unresponsive
  • You require real-time, ultra-low-latency predictions (API calls incur network overhead)

Inputs

  • JSON list of dictionaries with 1H and 13C peak keys and chemical shift values
  • Model metadata retrieved from /model/metadata endpoint

Outputs

  • JSON response containing classification predictions
  • Confidence scores for each prediction
  • Structured log file with request parameters, timestamp, and results

How to apply

First, query the /model/metadata endpoint via TensorFlow Serving to confirm the current input schema and model version, since model input names may change and require code updates. Construct a JSON payload as a list of dictionaries, where each dictionary contains 1H and 13C as keys with corresponding chemical shift values. Execute a POST request to the /api/smart3/search endpoint with this JSON payload as the request body. Validate the HTTP response status code and parse the returned JSON structure to extract classification predictions and their associated confidence scores. Log the request parameters, response timestamp, and prediction results to a structured output file for audit and reproducibility.

Related tools

  • TensorFlow Serving (Hosts the /model/metadata endpoint to retrieve current input schema and model version; serves the underlying SMART 3 classification model)
  • DeepSAT (Provides the /api/smart3/search REST endpoint for programmatic spectral classification via peak submission) — https://github.com/mwang87/DeepSAT

Examples

import requests; peaks = [{'1H': 7.25, '13C': 128.5}, {'1H': 3.45, '13C': 65.3}]; response = requests.post('http://api.deepsat.example.com/api/smart3/search', json=peaks); print(response.json())

Evaluation signals

  • HTTP response status code is 200 (or other expected success code) and response body is valid JSON
  • Returned JSON contains expected classification prediction keys and confidence score values within valid numeric ranges (e.g., 0–1 for probabilities)
  • Request payload matches the schema confirmed by /model/metadata (1H and 13C keys present)
  • Structured log file is created and contains non-empty request parameters, ISO-formatted timestamp, and prediction results
  • Model version in /model/metadata response matches the expected version documented for this analysis

Limitations

  • Model input names may change; code must be updated if /model/metadata schema changes
  • No changelog is maintained, making it difficult to track model version updates and breaking changes
  • API endpoint availability and latency depend on remote service uptime
  • Requires network connectivity; offline classification is not possible with this approach

Evidence

  • [intro] We pass through tensorflow serving at this url: /model/metadata: "We pass through tensorflow serving at this url: /model/metadata"
  • [intro] You can put in your peaks as a json list of dicts, with 1H,13C as headers: "You can put in your peaks as a json list of dicts, with 1H,13C as headers"
  • [intro] Classify programmatically. You can put in your peaks as a json list of dicts: "Classify programmatically. You can put in your peaks as a json list of dicts, with 1H,13C as headers"
  • [intro] If the model input names change, then we need to change it in the code: "If the model input names change, then we need to change it in the code"
  • [discussion] Source: github:mwang87__DeepSAT: "github:mwang87__DeepSAT"

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.