Skip to content

Conversation

@grantdfoster
Copy link
Collaborator

What

Support the two new tiktok apify capabilities, searchbyquery and searchbytrending, both with their own unique actors!

Why

How are you supposed to transcribe tiktok videos if you can't search for them!?

@grantdfoster
Copy link
Collaborator Author

Noting here that the worker detection should actually see if said apify key currently "rents out" the required actors! Need to research a way to pull this off for

epctex~tiktok-search-scraper
lexis-solutions~tiktok-trending-videos-scraper

@mudler mudler requested a review from Copilot August 22, 2025 09:51

This comment was marked as outdated.

@mcamou
Copy link
Contributor

mcamou commented Aug 22, 2025

Noting here that the worker detection should actually see if said apify key currently "rents out" the required actors! Need to research a way to pull this off for

epctex~tiktok-search-scraper lexis-solutions~tiktok-trending-videos-scraper

Since we'll have more of these (thinking of Reddit) we probably want to have a map of those that we're using (strongly typed, yada yada yada) and the capabilities they enable. We will probably end up having to make an Apify request for each actor.

I wonder, if you make an invalid request (i.e. include no fields except for dummy or something like that), is there a difference in the response if you include a valid token that has rented the actor vs. one that has not?

@mudler mudler requested a review from Copilot August 26, 2025 07:07

This comment was marked as outdated.

@grantdfoster grantdfoster self-assigned this Aug 26, 2025
@grantdfoster grantdfoster requested a review from mcamou August 26, 2025 20:05
@mudler mudler requested a review from Copilot August 27, 2025 07:11
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds TikTok search capabilities by integrating Apify actors for searching TikTok content. The implementation supports two new search methods: "searchbyquery" for searching by terms and "searchbytrending" for finding trending videos.

  • Adds TikTok Apify client with two search actors for query and trending searches
  • Refactors TikTok job handling to support multiple capabilities (transcription + search)
  • Updates capability detection to include TikTok search when Apify API key is available

Reviewed Changes

Copilot reviewed 12 out of 13 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
internal/jobserver/jobserver.go Updates TikTok job registration to use unified scraper
internal/jobs/webscraper.go Fixes type assertion for web arguments
internal/jobs/twitter.go Removes Apify validation code and fixes type assertion
internal/jobs/tiktokapify/client.go New TikTok Apify client implementation
internal/jobs/tiktok_test.go Adds comprehensive tests for TikTok search capabilities
internal/jobs/tiktok.go Major refactor to support multiple TikTok job types
internal/jobs/stats/stats.go Adds new TikTok-specific statistics
internal/capabilities/detector_test.go Converts tests to Ginkgo format and adds Apify tests
internal/capabilities/detector.go Adds Apify validation and TikTok search capability detection
go.mod Updates tee-types dependency
Makefile Updates test target for TikTok tests
Comments suppressed due to low confidence (1)

internal/jobs/tiktok.go:139

  • The code references jobArgs which is not defined in this function scope. This line should be part of executeTranscription function, not the removed code section.
	// Use the centralized type-safe unmarshaller

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link
Contributor

@mcamou mcamou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved as soon as you resolve the merge conflicts :-) I updated tee-types so the current version is 1.1.12 (which should include the changes in your last PR)

@grantdfoster grantdfoster merged commit 9bf57f1 into main Aug 27, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants