{"agent":"codex","input":"A GitHub issue labelled agent asks for the contacts table in this Flask and htmx app to load more rows as the user scrolls. Read app.py, contacts_model.py, templates/layout.html, templates/index.html, templates/rows.html, static/js/rsjs-menu.js and contacts.json first, and say in the pull request how paging works today, including any page parameter that is parsed and not used. Page the list and the search on the server and have both report whether another page exists. Put the trigger on the last row in rows.html: hx-get to the next page with the current q, hx-trigger revealed and hx-swap afterend, plus a plain link for visitors without JavaScript. Return bare rows only for an htmx request that is not boosted, and the full page otherwise. Keep the active search working: a new search must replace the rows and reset paging. Make the page size a setting. Add pytest tests with the Flask test client against generated contacts in a temporary copy of contacts.json, never the committed file: first page, last page, a page past the end, a search with a next page, and a boosted request. Start the app with a few hundred generated contacts, scroll the table in the browser, record the page requests, and confirm on a row loaded by scrolling that its checkbox updates the selected count and its Options menu opens. Finish with git status to show contacts.json is not modified, and open a pull request that closes the issue.","resources":[{"url":"https://github.com/your-org/your-app"}]}