API-Miner: an API-to-API Specification Recommendation Engine
- URL: http://arxiv.org/abs/2212.07253v2
- Date: Wed, 19 Jul 2023 17:30:33 GMT
- Title: API-Miner: an API-to-API Specification Recommendation Engine
- Authors: Sae Young Moon, Gregor Kerr, Fran Silavong, Sean Moran
- Abstract summary: API-Miner is an API-to-API specification recommendation engine.
It retrieves relevant specification components written in OpenAPI.
We evaluate API-Miner in both quantitative and qualitative tasks.
- Score: 1.8352113484137629
- License: http://creativecommons.org/licenses/by-nc-sa/4.0/
- Abstract: When designing a new API for a large project, developers need to make smart
design choices so that their code base can grow sustainably. To ensure that new
API components are well designed, developers can learn from existing API
components. However, the lack of standardized methods for comparing API designs
makes this learning process time-consuming and difficult. To address this gap
we developed API-Miner, to the best of our knowledge, one of the first
API-to-API specification recommendation engines. API-Miner retrieves relevant
specification components written in OpenAPI (a widely adopted language used to
describe web APIs). API-miner presents several significant contributions,
including: (1) novel methods of processing and extracting key information from
OpenAPI specifications, (2) innovative feature extraction techniques that are
optimized for the highly technical API specification domain, and (3) a novel
log-linear probabilistic model that combines multiple signals to retrieve
relevant and high quality OpenAPI specification components given a query
specification. We evaluate API-Miner in both quantitative and qualitative tasks
and achieve an overall of 91.7% recall@1 and 56.2% F1, which surpasses baseline
performance by 15.4% in recall@1 and 3.2% in F1. Overall, API-Miner will allow
developers to retrieve relevant OpenAPI specification components from a public
or internal database in the early stages of the API development cycle, so that
they can learn from existing established examples and potentially identify
redundancies in their work. It provides the guidance developers need to
accelerate development process and contribute thoughtfully designed APIs that
promote code maintainability and quality. Code is available on GitHub at
https://github.com/jpmorganchase/api-miner.
Related papers
- A Systematic Evaluation of Large Code Models in API Suggestion: When, Which, and How [53.65636914757381]
API suggestion is a critical task in modern software development.
Recent advancements in large code models (LCMs) have shown promise in the API suggestion task.
arXiv Detail & Related papers (2024-09-20T03:12:35Z) - FANTAstic SEquences and Where to Find Them: Faithful and Efficient API Call Generation through State-tracked Constrained Decoding and Reranking [57.53742155914176]
API call generation is the cornerstone of large language models' tool-using ability.
Existing supervised and in-context learning approaches suffer from high training costs, poor data efficiency, and generated API calls that can be unfaithful to the API documentation and the user's request.
We propose an output-side optimization approach called FANTASE to address these limitations.
arXiv Detail & Related papers (2024-07-18T23:44:02Z) - WorldAPIs: The World Is Worth How Many APIs? A Thought Experiment [49.00213183302225]
We propose a framework to induce new APIs by grounding wikiHow instruction to situated agent policies.
Inspired by recent successes in large language models (LLMs) for embodied planning, we propose a few-shot prompting to steer GPT-4.
arXiv Detail & Related papers (2024-07-10T15:52:44Z) - Contextual API Completion for Unseen Repositories Using LLMs [6.518508607788089]
We introduce a novel technique to mitigate hallucinations by leveraging global and local contextual information within a code repository for API completion tasks.
Our approach is tailored to refine code completion tasks, with a focus on optimizing local API completions.
Our tool, LANCE, surpasses Copilot by 143% and 142% for API token completion and conversational API completion, respectively.
arXiv Detail & Related papers (2024-05-07T18:22:28Z) - Are Human Rules Necessary? Generating Reusable APIs with CoT Reasoning and In-Context Learning [14.351476383642016]
We propose a novel approach, named Code2API, to automatically perform APIzation for Stack Overflow code snippets.
Code2API does not require additional model training or any manual crafting rules.
It can be easily deployed on personal computers without relying on other external tools.
arXiv Detail & Related papers (2024-05-06T14:22:17Z) - APIGen: Generative API Method Recommendation [16.541442856821]
APIGen is a generative API recommendation approach through enhanced in-context learning (ICL)
APIGen searches for similar posts to the programming queries from the lexical, syntactical, and semantic perspectives.
With the reasoning process, APIGen makes recommended APIs better meet the programming requirement of queries.
arXiv Detail & Related papers (2024-01-29T02:35:42Z) - Leveraging Large Language Models to Improve REST API Testing [51.284096009803406]
RESTGPT takes as input an API specification, extracts machine-interpretable rules, and generates example parameter values from natural-language descriptions in the specification.
Our evaluations indicate that RESTGPT outperforms existing techniques in both rule extraction and value generation.
arXiv Detail & Related papers (2023-12-01T19:53:23Z) - APICom: Automatic API Completion via Prompt Learning and Adversarial
Training-based Data Augmentation [6.029137544885093]
API recommendation is the process of assisting developers in finding the required API among numerous candidate APIs.
Previous studies mainly modeled API recommendation as the recommendation task, and developers may not yet be able to find what they need.
Motivated by the neural machine translation research domain, we can model this problem as the generation task.
We propose a novel approach APICom based on prompt learning, which can generate API related to the query according to the prompts.
arXiv Detail & Related papers (2023-09-13T15:31:50Z) - Private-Library-Oriented Code Generation with Large Language Models [52.73999698194344]
This paper focuses on utilizing large language models (LLMs) for code generation in private libraries.
We propose a novel framework that emulates the process of programmers writing private code.
We create four private library benchmarks, including TorchDataEval, TorchDataComplexEval, MonkeyEval, and BeatNumEval.
arXiv Detail & Related papers (2023-07-28T07:43:13Z) - Evaluating Embedding APIs for Information Retrieval [51.24236853841468]
We evaluate the capabilities of existing semantic embedding APIs on domain generalization and multilingual retrieval.
We find that re-ranking BM25 results using the APIs is a budget-friendly approach and is most effective in English.
For non-English retrieval, re-ranking still improves the results, but a hybrid model with BM25 works best, albeit at a higher cost.
arXiv Detail & Related papers (2023-05-10T16:40:52Z)
This list is automatically generated from the titles and abstracts of the papers in this site.
This site does not guarantee the quality of this site (including all information) and is not responsible for any consequences.