
Security News
PodRocket Podcast: Inside the Recent npm Supply Chain Attacks
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
@arugaz/ai2d
Advanced tools
$ npm install --save @arugaz/ai2d
$ yarn add @arugaz/ai2d
Before use this package, You have to add sharp or jimp to dependencies.
import AI2D from "@arugaz/ai2d";
await AI2D(`Buffer | Base64 | Url | Path`, options);
// default
await AI2D("https://nekopoi.care/image.png"); //=> Buffer
// crop
await AI2D("https://nekopoi.care/image.png", {
crop: "SINGLE", // SINGLE | COMPARED
}); //=> Buffer
// proxy
await AI2D("https://nekopoi.care/image.png", {
proxy: "socks5://11.22.33.44:1234" // support https & socks
}); //=> Buffer
// with async-retry opts
await AI2D("https://nekopoi.care/image.png", {
crop: "COMPARED",
retries: 100,
factor: 3,
randomize: false,
}); //=> Buffer
The options
are
crop
: COMPARED | SINGLE. Default didnt crop the image.proxy
: Your URL Proxy, support https or socks proxyretries
: The maximum amount of times to retry the operation. Default is 10
.factor
: The exponential factor to use. Default is 1
.minTimeout
: The number of milliseconds before starting the first retry. Default is 1000
.maxTimeout
: The maximum number of milliseconds between two retries. Default is Infinity
.randomize
: Randomizes the timeouts by multiplying with a factor between 1
to 2
. Default is true
.onRetry
: an optional Function
that is invoked after a new retry is performed. It's passed the Error
that triggered it as a parameter.forever
: Whether to retry forever.unref
: Whether to unref the setTimeout's.From
December 6
toDecember 15
the AI had been available only inChina
or withChinese proxies
. SinceDecember 16
the AIworks
for the rest of the world (UPD: still doesn't work in some countries) again so using proxies is not needed anymore, but it's limited and allows you to generate only one type of media. Seems likeit's impossible
to findFREE alive proxies
. Don't waste your time searching andjust buy it
somewhere.
FAQs
Generate a hyper-realistic photo an anime style!
The npm package @arugaz/ai2d receives a total of 66 weekly downloads. As such, @arugaz/ai2d popularity was classified as not popular.
We found that @arugaz/ai2d demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket CEO Feross Aboukhadijeh discusses the recent npm supply chain attacks on PodRocket, covering novel attack vectors and how developers can protect themselves.
Security News
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
Product
Socket Firewall is a free tool that blocks malicious packages at install time, giving developers proactive protection against rising supply chain attacks.