add-function

Add new functions to the Semantic Link Labs Python library with imports, decorators, tests, and documentation.

561|190|Updated May 16, 2024
One-click install
npx skills add https://github.com/microsoft/semantic-link-labs --skill add-function
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: add-function
Source: https://github.com/microsoft/semantic-link-labs/tree/main/.claude/skills/add-function
Command: npx skills add https://github.com/microsoft/semantic-link-labs --skill add-function

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill streamlines the process of adding new functions to the Semantic Link Labs library, ensuring consistency and adherence to best practices.

Core Features & Use Cases

  • Guided Function Creation: Provides a step-by-step workflow for implementing new API wrappers or utility functions.
  • Code Structure & Export: Details where to place new functions and how to export them for library use.
  • Testing & Documentation: Emphasizes the importance of writing tests and documenting functions using numpydoc style.
  • Use Case: A developer needs to add a new function to interact with a Fabric workspace API. They use this Skill to understand the correct file location, necessary imports, function signature, docstring format, and testing requirements.

Quick Start

Use the add-function skill to create a new function for the library following the provided template and checklist.

Frequently Asked Questions about add-function

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add new functions to the Semantic Link Labs Python library?

To add new functions to the Semantic Link Labs Python library, follow a guided workflow covering file location selection, writing code with imports and decorators, exporting the function, and adding tests with numpydoc documentation.

What coding standards are required when creating a Python API wrapper for a Fabric workspace?

Creating a Python API wrapper requires adhering to coding standards that include using necessary imports, applying required decorators, structuring function signatures correctly, and writing numpydoc style docstrings for documentation.

Do I need to write tests and documentation when adding a function to a Python library?

Writing tests and documentation is required when adding a function to the library, ensuring consistency and adherence to best practices by utilizing the numpydoc docstring style and provided testing templates.

What is the correct file location for adding top-level or admin functions in a Python library?

The correct file location depends on the function category, with the Skill guiding placement for top-level, admin, report, lakehouse, and TOM methods to maintain proper library structure and export paths.

How does the function export process work for new Python library methods?

The function export process involves placing the function in the correct category file, applying required decorators, and registering it for export to ensure it is available for library use and testing.