{"id":15460912,"url":"https://github.com/machawk1/archivethumbnails","last_synced_at":"2025-04-30T23:50:00.889Z","repository":{"id":15861381,"uuid":"18601839","full_name":"machawk1/ArchiveThumbnails","owner":"machawk1","description":"An implementation for Ahmed AlSum's \"Thumbnail Summarization Techniques for Web Archives\"","archived":false,"fork":false,"pushed_at":"2024-03-26T14:30:47.000Z","size":23521,"stargazers_count":7,"open_issues_count":40,"forks_count":5,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-30T23:49:50.815Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/machawk1.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":"support/faye/faye-browser-min.js","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-04-09T15:11:03.000Z","updated_at":"2024-03-26T14:30:52.000Z","dependencies_parsed_at":"2024-10-24T02:08:40.304Z","dependency_job_id":"37d6aafb-2331-4cfb-bef9-6cae9770d745","html_url":"https://github.com/machawk1/ArchiveThumbnails","commit_stats":{"total_commits":258,"total_committers":3,"mean_commits":86.0,"dds":0.06589147286821706,"last_synced_commit":"7f5e26fab33c27a5a0fde9779bb8bf7077bbea75"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/machawk1%2FArchiveThumbnails","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/machawk1%2FArchiveThumbnails/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/machawk1%2FArchiveThumbnails/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/machawk1%2FArchiveThumbnails/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/machawk1","download_url":"https://codeload.github.com/machawk1/ArchiveThumbnails/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251801087,"owners_count":21645968,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-01T23:40:01.597Z","updated_at":"2025-04-30T23:50:00.865Z","avatar_url":"https://github.com/machawk1.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"ArchiveThumbnails\n================\n\nAn implementation of Ahmed AlSum's 2014 ECIR paper titled [\"Thumbnail Summarization Techniques for Web\nArchives\"](http://www.cs.odu.edu/~mln/pubs/ecir-2014/ecir-2014.pdf) for the Web Archiving Incentive Program for Columbia University Libraries' grant, \"Visualizing Digital Collections of Web Archives\".\n\n![Screenshot](_meta/screenshot.png)\n\n## Requirements\n\n[Node.js](https://nodejs.org/) is required to run the service. Once Node is installed, the packages required to use the service can be installed by running `npm install -g` in the root of the project directory. [PhantomJS](http://phantomjs.org/) may also additionally be required depending on your system configuration.\n\n## Running\n\nTo execute the code, run `node AlSummarization.js`.\n\nTo query the server instance generated using your browser visit `http://localhost:15421/?URI-R=http://matkelly.com`, substituting the URI-R to request a different site's summarization. The additional parameters of `access` and `strategy` can be used to change the summarization process, specifying the means of access and the strategy used for summarization (respectively). `access` can be one of `interface`, `embed`, or `wayback`. `strategy` can be `alSummarization`, `random`, `interval`, or `temporalInterval`.\n\n### Example URIs\n\n* `http://localhost:15421/?URI-R=http://matkelly.com`\n* `http://localhost:15421/?access=embed\u0026URI-R=http://matkelly.com`\n* `http://localhost:15421/?strategy=random\u0026URI-R=http://matkelly.com`\n* `http://localhost:15421/?access=wayback\u0026strategy=yearly\u0026URI-R=http://matkelly.com`\n* `http://localhost:15421/http://matkelly.com`\n\n## Running as a Docker Container (experimental)\n\nRunning the server in a [Docker](https://www.docker.com/) container can make the process of dependency management easier. The code is shipped with a `Dockerfile` to build a Docker image that will run the service when started. This document assumes that you have Docker setup already, if not then follow the [official guide](https://docs.docker.com/installation/).\n\n### Building Docker Image\n\nClone the repository and change working directory (if not already) then build the image.\n\n```\n$ git clone https://github.com/machawk1/ArchiveThumbnails.git\n$ cd ArchiveThumbnails\n$ docker image build -t archthumb .\n```\n\nIn the above command `archthumb` is the name of the image which can be anything, but the same needs to be used when running the container instance.\n\n### Running Docker Container\n\n```\n$ docker container run -d -p 15421:15421 -p 15422:15422 -p 1338:1338 archthumb\n```\n\nIn the above command the container is running in detached mode and can be accessed from outside on port `15421` at http://localhost:15421/. If you want to run the service on a different port, say `80` then change `-p 15421:15421` to `-p 80:15421`.\n\nIn order to persist generated thumbnails, mount a host directory as a volume inside the container by adding `-v /SOME/HOST/DIRECTORY:/app/screenshots` flag when running the container.\n\nContainer is completely transparent from the outside and it will be accessed as if the service is running in the host machine itself.\n\nIn case if you want to make changes in the `ArchiveThumbnails` code itself, you might want to run it in the development mode by mounting the code from the host machine inside the container so that changes are reflected immediately, without requiring an image rebuild. Here is a possible workflow:\n\n```\n$ git clone https://github.com/machawk1/ArchiveThumbnails.git\n$ cd ArchiveThumbnails\n$ docker image build -t archthumb .\n$ docker container run -it --rm -v \"$PWD\":/app archthumb npm install\n$ docker container run -it --rm -v \"$PWD\":/app -p 15421:15421 -p 15422:15422 -p 1338:1338 archthumb\n```\n\nOnce the image is built and dependencies are installed locally under the `node_modules` directory of the local clone, only the last command would be needed for continuous development. Since the default container runs under the `root` user, there might be permission related issues on the `npm install` step. If so, then try to manually create the `node_modules` directory and change its permissions to world writable (`chmod -R a+w node_modules`) then run the command to install dependencies again.\n\n### Running via Docker Compose\n\nAn alternate way of running the service container is using [Docker Compose](https://docs.docker.com/compose/). We have provided a default `docker-compose.yml` file to build and run the container easily. Provided that the Docker daemon is running and the Docker Compose binary is installed, running following command from the directory where this repository is checked out will build an image if necessary and spin a container.\n\n```\n$ docker-compose up -d\n```\n\nThe `docker-compose.yml` file has port mapping as described in the previous section. Additionally it also makes the generated thumbnail persistent on the host machine in the `thumbnails` directory under this checked out code directory. Please feel free to modify or inherit from the `docker-compose.yml` file according to your needs.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmachawk1%2Farchivethumbnails","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmachawk1%2Farchivethumbnails","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmachawk1%2Farchivethumbnails/lists"}