Ragex.URLAnalyzer.Classifier (Ragex v0.30.0)

View Source

Classifies input URLs into specific target categories for tailored analysis:

  • :git_repo - GitHub, GitLab, Bitbucket, or standard Git repository URLs.
  • :raw_code - Direct links to code files, gists, or raw source URLs.
  • :api_spec - OpenAPI/Swagger or JSON/YAML API specification endpoints.
  • :web_page - Web pages, technical documentation, or HTML sites.

Summary

Functions

Determines the target type for a given URL string.

Functions

classify(url_string)

Determines the target type for a given URL string.

Returns {:ok, target_type, metadata} or {:error, reason}.