https://github.com/capjamesg/seotools

A set of utilities for SEOs and web developers with which to complete common tasks.

https://github.com/capjamesg/seotools

Science Score: 13.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.0%) to scientific vocabulary

Keywords

link-graph seo seo-optimization
Last synced: 6 months ago · JSON representation

Repository

A set of utilities for SEOs and web developers with which to complete common tasks.

Basic Info
Statistics
  • Stars: 8
  • Watchers: 2
  • Forks: 1
  • Open Issues: 0
  • Releases: 0
Topics
link-graph seo seo-optimization
Created over 2 years ago · Last pushed over 2 years ago
Metadata Files
Readme License

README.md

version downloads license python-version

SEOtools 🛠️

A set of utilities for SEOs and web developers with which to complete common tasks.

With SEOtools, you can:

  1. Programatically add links to related posts in content.
  2. Calculate PageRank on internal links from your sitemap.
  3. Identify broken links on a web page.
  4. Recommend a post to use as canonical for a given keyword.
  5. Find the distance of pages from your home page.

And more!

Installation 💻

You can install SEOtools using pip:

bash pip install seotools

Quickstart 🚀

Create a link graph

```python from seotools.app import Analyzer

load from disk will load the link graph from disk if it has already been created

otherwise, a new link graph will be created

analyzer = Analyzer("https://jamesg.blog/sitemap.xml", loadfromdisk=True) ```

Get pagerank of a URL

python print(analyzer.pagerank["https://jamesg.blog"])

Add relevant internal links to a web page

```python import markdown

article = markdown.markdown(BeautifulSoup(article.text, "html.parser").get_text())

keywordreplacecount = 0

for keyword, url in keywordmap.items(): if keywordreplacecount >= MAXKEYWORD_REPLACE: break

article = article.replace(keyword, f"<a href='{url}'>{keyword}</a>", 1)
keyword_replace_count += 1

print(article) ```

Recommend related content for a "See Also" section

```python article = requests.get("https://jamesg.blog/...")

article = markdown.markdown(BeautifulSoup(article.text, "html.parser").get_text())

urls = analyzer.recommendrelatedcontent(article.text) ```

Check if a page contains a particular JSON-LD object

```python from seotools import pagecontainsjsonld import requests

content = requests.get("https://jamesg.blog")

print(pagecontainsjsonld(content, "FAQPage")) ```

Get subfolders in a sitemap

python analyzer.get_subpaths()

Get distance of URL from home page

python analyzer.get_distance_from_home_page("https://jamesg.blog/2023/01/01/")

Retrieve keywords that appear more than N times on a web page

```python from seotools import get_keywords import requests from bs4 import BeautifulSoup

article = requests.get("https://jamesg.blog/...").text parsedarticle = BeautifulSoup(article, "html.parser").gettext()

get keywords that appear more than 10 times

keywords = getkeywords(parsedarticle, 10) ```

See Also 📚

License 📝

This project is licensed under an MIT license.

Owner

  • Name: James
  • Login: capjamesg
  • Kind: user
  • Location: Scotland
  • Company: @Roboflow

from words, wonder.

GitHub Events

Total
Last Year

Committers

Last synced: over 1 year ago

All Time
  • Total Commits: 16
  • Total Committers: 1
  • Avg Commits per committer: 16.0
  • Development Distribution Score (DDS): 0.0
Past Year
  • Commits: 0
  • Committers: 0
  • Avg Commits per committer: 0.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
capjamesg j****g@j****g 16
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 0
  • Total pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Total issue authors: 0
  • Total pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 21 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 4
  • Total maintainers: 1
pypi.org: seotools

A collection of tools for use with writing SEO-related programs in Python.

  • Versions: 4
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 21 Last month
Rankings
Dependent packages count: 7.5%
Downloads: 13.7%
Forks count: 30.2%
Average: 32.0%
Stargazers count: 39.1%
Dependent repos count: 69.7%
Maintainers (1)
Last synced: 6 months ago