尚未检测到更新。GitHub 发布版本后会显示在这里。
个人 GitHub 账号下公开仓库的所有者可以登录并验证所有权,自行管理介绍,无需管理员批准。
登录并生成验证文件,在 30 分钟内将其提交到此仓库的默认分支。其他分支或分叉仓库中的文件无效。然后在下方检查文件,即可无需管理员批准直接管理项目。请保留文件以维持管理权限。
如需登录,将前往登录页面。登录后请回到此处,再次点击所选的验证按钮。
在项目文件夹中运行 /nomorevibe verify,即可验证所有权并自行管理介绍。
一分钟完成验证制作者的介绍仅有上面的一句话。 更多详情请阅读仓库 README。 仓库 README ↗
正在加载完整 README。
查看完整 README ↗A daily art guessing game. Each day Artle shows one artwork from the Harvard Art Museums collection, and you get six tries to guess the country it was made in. After each guess you see how far away the right country is and which way to go (like "1,200 km ↗ NE").
The artwork starts zoomed in and in black and white. Each wrong guess reveals more: it zooms out, then shows the color, then the date and finally the medium.
After the daily puzzle you can keep playing unlimited rounds of random
artworks. Each round has its own link, like /unlimited/2bm, so you can send
a friend the same artwork.
Built with Next.js and the Harvard Art Museums API.
sort=random:20261020), so everyone gets the same
artwork on the same day. Each artwork's creation place, like
"Europe, France, Paris", is matched to a country, and artworks that can't
be matched are skipped. A country is then picked evenly from those in the
sample, since a purely random pick would almost always be American or
western European. See src/lib/puzzle.ts./unlimited picks a random artwork and redirects to
its round page. Rounds come from 100 fixed samples of the collection, and a
round id like 2bm packs the sample number and the artwork's position in
it, so anyone with the link gets the same artwork without the link giving
it away. See src/app/unlimited/.mediumClue in src/lib/puzzle.ts).src/lib/geo.ts.src/lib/harvard.ts). The browser gets the image and the clues,
but not the answer: guesses are checked by src/app/api/guess/route.ts,
which only reveals the artwork once the game is over."use cache: remote", and there are only about
100 of them in use (today's puzzle plus the unlimited samples), so the API
is called a handful of times a day however many people play.localStorage. Unlimited rounds don't count toward stats.A new puzzle starts every day at midnight Eastern Time.
Request a free API key at https://harvardartmuseums.org/collections/api.
Copy .env.example to .env.local and paste your key after HARVARD_API_KEY=.
.env.local is ignored by git, so the key won't be committed.
Install and start the dev server:
npm install
npm run dev
Open http://localhost:3000.
Other commands:
npm test # unit tests for the game logic
npm run lint
npm run build # production build
vercel.json
tells Vercel it's a Next.js app, so the default build settings are fine.HARVARD_API_KEY with your key as the
value. Don't prefix it with NEXT_PUBLIC_: that would expose it to every
visitor's browser.After that, every push to the production branch redeploys the site, and every other branch gets its own preview URL. If you add or change an environment variable later, redeploy (Deployments → ⋯ → Redeploy) for it to take effect.
If the site shows "The gallery is closed", today's artwork couldn't be loaded. The reason will be in the project's Logs tab on Vercel.
src/
app/
page.tsx the daily puzzle
unlimited/route.ts starts a random unlimited round
unlimited/[round]/ an unlimited round's page
api/guess/route.ts checks a guess and reveals the answer at the end
components/ the game UI (client components)
lib/
harvard.ts Harvard Art Museums API client (server only)
puzzle.ts picks artworks, builds clues, round ids
countries.ts countries, their other names, and search
geo.ts distances and compass directions
dates.ts puzzle dates and numbering (Eastern Time)
game.ts saved games, stats and the share text
Artle is a fan project and isn't affiliated with the Harvard Art Museums.