Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

chore(workflows): remove the workflow-ai-task-action flag (#115154)

posthog[bot]b846ad321e21
diff --git a/frontend/snapshots.yml b/frontend/snapshots.yml
index 1ed6ac083780..7cdf94d9bc3e 100644
--- a/frontend/snapshots.yml
+++ b/frontend/snapshots.yml
@@ -8375,9 +8375,9 @@ snapshots:
products-workflows-editor-configuration-panel--build--light:
hash: v1.k794b7964.68f9e8d6025533cc2b82375fa065822c639c4174d0112a13de8b8fcdf0a673f0.VgfO6Zb4jIczGth1k5UuTFh_X65d8wT8wYkuM886TqE
products-workflows-editor-configuration-panel--build-palette--dark:
- hash: v1.k794b7964.a8f60d80b845e79fe2715e0666ac5320bd8aa35b860a5bef16a75ba7b14cb96e.zyaYmHlT4lPVloDTLSHZbf5I0rj5q2kAK2ZBS9wKmng
+ hash: v1.k794b7964.8c4db943f81e773cea8c5a200d6f3c18ccf839dd416167cb5952828943356223.pzLDyV2mYfv18mUMVxFcZtOUH9wyLc6-VbJovO4xKI8
products-workflows-editor-configuration-panel--build-palette--light:
- hash: v1.k794b7964.24781e6a28a983475fe79719121d7f5e8b095a0b3b0b3e5ee65dc5fd6001e9ea.7su3Dcu8hL3XRv6Ivyl6SWkmz7Ce7XT_CnTHK8wwsP0
+ hash: v1.k794b7964.bb0ec76fa80bf963c7dc2fc60d34e3e5ac217983c2a5af4f290d136cea1cda34.XdqbwvU8p-Rfe2N0_NMJP6axztA6cdIzFFHWVW94ZGQ
products-workflows-editor-configuration-panel--cohort-branch--dark:
hash: v1.k794b7964.89705899ccfa2ee8b18d86d538e800a3a25e91fd25261d88738dd97809388c45.waPXpQ-N2vcu8Ta_GIKzoX0InqMySnxWOXWn6BsfA4g
products-workflows-editor-configuration-panel--cohort-branch--light:
@@ -8419,37 +8419,37 @@ snapshots:
products-workflows-editor-configuration-panel--webhook--light:
hash: v1.k794b7964.50f31a08c94115097306a76810343499b35294055b5f6a96d8466a77ff6dd72c.KgUwEqV9D2ROlg3pazBZGDM3-z7W6595ojBL0uvLGRc
products-workflows-editor-graph--add-on-promotion-emails--dark:
- hash: v1.k794b7964.5d37d34ca5aa7b35f278cb1bb1bb6b8546f76cb8c7cac834bc70a503adce6808.Ey0Bf5z3N1u07UPAirdjqG1c09FJDG41oVedkWmAKDE
+ hash: v1.k794b7964.d09d47c2e08108e179ccc2329cad258baa0d76936028631f6f83fdbb72fed6df.SUCRLKNn9Ef2NM99NcBkHn7xAU10G-Z7jRC6v8rM2Us
products-workflows-editor-graph--add-on-promotion-emails--light:
- hash: v1.k794b7964.1a421bcaa9a38c04ba753d04fb9d41d0ce5e263a7ea3a30c39d6a5bb8f06b7aa.z0noLKRLCZoHD_hcief-gRWUnpQoY0yFsCp1y0_uiEo
+ hash: v1.k794b7964.459a11941ad814aa75cad1b59e93055d1b4e2d2492efad36811ed7376799c32c.yDEGEvDRXv70gpBYs1J4xUYOVajQiYsLUqD_POtqyc0
products-workflows-editor-graph--customer-onboarding-and-retention--dark:
- hash: v1.k794b7964.7445670bee0bfaeb2021e071e56177c5276231041ad2cd854e18545ae8b9691c.QTQd1qU_rT-yMraSYD__5zJcJiZ6QZY9nV9y4wJdop8
+ hash: v1.k794b7964.8c290175ab272717691996848ddf6466bb9e5160b9f669e0665ec632e59b1673._TrlJjNnqHR2O3aFlhOTHvvguIP4kpTamCtDeOCZyGI
products-workflows-editor-graph--customer-onboarding-and-retention--light:
- hash: v1.k794b7964.6f92a725109f9b183372abd97830630bea1df865b03453bdd080a107e961b88a.vpYbUnFGxRN6IGSY2l7dIj1jJx4ieYI1NigVi-z91Y4
+ hash: v1.k794b7964.48ad3619a33844194ad5be15229368ac911b778a3f0960537c8c7709cc1f33ca.g25NilPWp5_YJQSWnQ9F5xsHYVNx0Vc6srQDuDCVZ0Y
products-workflows-editor-graph--narrow-workflow--dark:
hash: v1.k794b7964.3c999b024c3fe403f0251807b6fed46dea0d1ce33635ba9c16d854fa5154fc6c.oe97w6gOWNlLBqVXmR9cwJdbsQT5ZVjAQxgdcBGiFYw
products-workflows-editor-graph--narrow-workflow--light:
hash: v1.k794b7964.03aac81ae100d88cfb99387fe789002177e4e7dbecc9d9d45ec6dcd4d62d73de.V4ht6ObddMF6m23ns1MmazNLEHKEPhZP2d7rs9Heg9g
products-workflows-editor-graph--new-workflow--dark:
- hash: v1.k794b7964.0f741c82e85f0787f27b38a4abadd2b283a13e091674f8953f5ff7b767cab535.Os4Th3eJ7fi-5GD5OOY3Om6ZxI94UYmQZKE6ZKaUfCA
+ hash: v1.k794b7964.f679d013a77cb96c53d5663ae2f66b0ad0230eb68ea5c98a4b579ab144ae1a70.EBukMpAzfN9dx4fJ_Vonsm3YoNL1G8ulVu0wfGt8MVA
products-workflows-editor-graph--new-workflow--light:
- hash: v1.k794b7964.637bed9376a57bcb2dbd146e11f333a2c799bd30b16b99014a0e0b29975d4352.mQFznpHe4o6lYM4ROt6x9PLkGGSXWLSGiLMgHXqn0kw
+ hash: v1.k794b7964.5ab94515bc86029887eb363444ab3acc988b2693b9289e714413890b8c189c54.IAalFCsHJCkj8Q0NBbpan57faqK9q0XLQ8OPsHFdrqs
products-workflows-editor-graph--pending-ticket-cleanup--dark:
- hash: v1.k794b7964.37f94bae55b2364375b003a3806b5524146fe399f74adc0343925fa3cd242c8c.t1MIwQcYQzBqGuaqsYblC7cb3LbknNvyTS0GOI03e0c
+ hash: v1.k794b7964.22405d49b71d11a6356fd0d7b866472ae6597cc33e7c01a4a762cb913407b729.6JlfZBvRiJ3zINRLxuV_oy-MOHRBFASpvIuxZ6xaFN4
products-workflows-editor-graph--pending-ticket-cleanup--light:
- hash: v1.k794b7964.a959e26cd38d167a8292fcdaa2cc139259a8294c7242e768289aa4d9a23c876f.1m7Go65l7sKV2dUzZSToEHHtc2dpnzhqcmUpN9JNRZY
+ hash: v1.k794b7964.6cb87844c46f6838bb75c24a1ecdf2f35dceef208fc1ecf08d2770debed3173b.hFUueQGNfRBRjUt8LEpN3kpVd-LZpy1zirfjpR0F9hg
products-workflows-editor-graph--renewal-window-alerts--dark:
- hash: v1.k794b7964.b46f08f130bee287fb48aa95722fa379303144452efe09f6460f77734a0903ff.WoohldeomOu-avveLngiAfSTHL2EJQhs1a3kcrgIoDg
+ hash: v1.k794b7964.0268f83b607849e9f60dc4c158c7b819bf16005f5a3a77b2223331e622d6eb50.Seq0j6y5K7FTu2zsefetLtFuYgXZVm_0Pa1FWijbckk
products-workflows-editor-graph--renewal-window-alerts--light:
- hash: v1.k794b7964.3e42eeaca7b7afada1db59167a2748121f017b1d45a76e5e7e79671339fe913a.w1Uj0t8Y-isaGcwUe-ieGs_WcMXZH79OD3ExBVG8pdk
+ hash: v1.k794b7964.19b0719a16b301cf66f73f434ab4db447c6bc0f9baca1dc4d211612c6b02c0a4.QGlrBZazFF9lt8eYqanWw4Ku6zncuc23tMq5QxftX0w
products-workflows-editor-graph--support-sla-routing--dark:
- hash: v1.k794b7964.2eb4d4a6c0ba9635f0915da639e310a95008307b8ebaca3f6f6204259c30a7b9.3HZ_VbUIJA_uWH-9J9zQusRNmJdIbTnHLkn5ohQX1eQ
+ hash: v1.k794b7964.1572d26439be4a89d722a1c02d81e73f81a4fffa435849418b9548e3a9805eaf.CqAqit6-Aqv2wb75sZQHagOAQMtRFS49IEMxHl39oXA
products-workflows-editor-graph--support-sla-routing--light:
- hash: v1.k794b7964.9c96bc895d1143f64476b67a113716deeddab6e9ab356d7b92c0617acca1b0c4.5vnrQ9xxx63Z2foYdxt3Wv_epK5UpDDWQDBFzP50eF0
+ hash: v1.k794b7964.7da9940d809322739e24142d5c513e9ea4cad9ff011779c5c26998cfaec24bb9.j7q5YusxDubsQpy3eiCFwNBRw6BeQUziOxHxIY7LaAk
products-workflows-editor-graph--with-navigation--dark:
- hash: v1.k794b7964.2034ac462aa68d73fa5bd96c4061c5140a33b165bd377be1d889a50715275bb0.idAfTEhk_aha6kvc1txhrs33W-XzI18viXvEszxE3aI
+ hash: v1.k794b7964.5f370b85344e6b2c4b44988d8bc2e13e647d1ae527720dce8d05e2b15a545381.H1s-o4FdoUogWavEbPSblWOU6HyHlCvOP8V-kI_fJyA
products-workflows-editor-graph--with-navigation--light:
- hash: v1.k794b7964.56d8bf045970b426f994709ddc19478d18e1968fcf3a41f8e0d28485ff338fa1.QsH5OKiKp00RMcqNzSYgsacI4_1BZ7UtU31Qt2EYzuU
+ hash: v1.k794b7964.80893cf0e8c8e443606cad555c64cc7e33323c3d4da76599c8e63f7ca1c291bd.5ATLbGHLQWlJfeMpGAo-7Zld7eNzLRqjOkp2MwxmpV4
products-workflows-editor-tile-canvas--long-emails--dark:
hash: v1.k794b7964.fd71da5c1231d1036556e7e58e34b68a931b14812134201ce9f7fb2008d195c9.Eyw-ZqzqCvOOfKSecjq358TQw_kZtHC2hXzISMuEP9Q
products-workflows-editor-tile-canvas--long-emails--light:
@@ -8471,37 +8471,37 @@ snapshots:
products-workflows-editor-tile-canvas--with-step-counts--light:
hash: v1.k794b7964.d28c0e207d14d3f1ee827602f1600c4e3eb47ec9c790e4357757388aa1172f9a.yjhNs4J_VVtzYX_ksVtLrSzDD0vw8lAknbYlYncjD9A
products-workflows-editor-tree--add-on-promotion-emails--dark:
- hash: v1.k794b7964.b57f08708c8687742a71ed295c7e0d342e11cc63c709a9b9b703385fbf4d1b31.yosoQWPjKotHOoPqaIycyvai4desJVjTgoOqJHZu1fA
+ hash: v1.k794b7964.17e5ae30b6cfa98729709e1bb572aa329eea7d267ee0fd757a8bcbb1d065f805.UCtBAJZoCAO4I9fElU_pbm8QniucCrnrfH8XHXnsEZA
products-workflows-editor-tree--add-on-promotion-emails--light:
- hash: v1.k794b7964.42a7ea9597446421c29d6a66c1be739a0785e32fa8bc01fa0631e45c01ccf27f.JyRPfVyBno2h2RhoZ-MGdY4ulkAvoGuio8S8DOa7g3k
+ hash: v1.k794b7964.f830380f7e4815a04d0194868c15ca52f1833cf78b57a69594fbd57402a0c561.5SP1lTTSGd3IzpqmDjcDcv1zuKatqfbNe1j7GkxPC9U
products-workflows-editor-tree--customer-onboarding-and-retention--dark:
- hash: v1.k794b7964.32edb139a5c92ca518c94f4dce7bc15bd377d858d71bc3dc06acc0d89efe835e.Mz4vpVsbYMtxUbEp7G3Kh4lglVKhn2eKeZ_1FFb7cbk
+ hash: v1.k794b7964.808a132ead05351093977b04223be9dedd9e0623a2ed4de7defd9a8a5ba5a5cc.UzaUo0418u_lhAD2HCPee68-9wGdgRdWaekPfYR5mQA
products-workflows-editor-tree--customer-onboarding-and-retention--light:
- hash: v1.k794b7964.995c915f7a5489f33d30a7fe0bc08fa5dcb4e472b240e0b171546575a1ee2ffe.HoKNMKTchqbOvxF-Q4WlbcR8MMnRZiGyN2vcwLWmHFA
+ hash: v1.k794b7964.67d1a2b0ef94f015512b92f398eaea2368b095f73a50aefd6f80a560081cf7bf.bNeVhwn053pmSIaXqid9kbk2prGjITRcrOeTls9PIqw
products-workflows-editor-tree--narrow-customer-onboarding-and-retention--dark:
- hash: v1.k794b7964.9ac4a8bb1a4f11a66be67b217d7ab3093fd62207d802dc3b6833798ef57ad035.RSFnsOczJV-EOiRJeET36HYoMPwl--thHqIpz71HEJE
+ hash: v1.k794b7964.673b09f7bfb1a2fb5f76a9d4e9fd654487b2dfb9e281556a4670cacf43dad021.CL7Ne89Gxo5uEAOHiOZ57sxijGimFQFEltj9marnNcs
products-workflows-editor-tree--narrow-customer-onboarding-and-retention--light:
- hash: v1.k794b7964.550ff1e6472745822f013aed0430a49a14c18817e83c593a9ca7cf525a7abd8c.gkmVYS9X3Oo9GLZfTk8WrLpSyCms8RoqjOka9rbH4RQ
+ hash: v1.k794b7964.314a6ca95c60c27d347ca282243c3302f888af0a6e7baa46c5b0e4199786f6cb.Zw8SsNDqanIMfgBrWRyc_VRFK5VDlTqkT6YAUpUGnKo
products-workflows-editor-tree--narrow-workflow--dark:
- hash: v1.k794b7964.73e01b3165b2ad9a663cb5073b1d4920c740d804fd5328aaf268438f56903e8a.MJ0pl8R1957YChGmSxqQbxs8C3-5g_zeV1ZDFUH1v6c
+ hash: v1.k794b7964.c5d5f2a2866b78902551f9e9380136d9be5a0011279f2e54f95377f013545b20.I-T3nqERLPDU8txzIe16BUhe78gHADq0jM4W39rAjYY
products-workflows-editor-tree--narrow-workflow--light:
- hash: v1.k794b7964.670b9b1e72a3eee969591af45a06ebf2aa0d12386ab9b723295110c24dbb457b.0_0pxPrjiatGut62B0vHpbI1LoFCCDoLS3SXYMoAYLA
+ hash: v1.k794b7964.7d8dac9b3eb931220260bb75055a56e7adcb05342e22d58003fa11574542dc24.Fj7P8W9ZEhkxhLJEd43nRkEoRGLmq0sstG1vv2rRa8I
products-workflows-editor-tree--new-workflow--dark:
- hash: v1.k794b7964.b328ce7fa3514451e42dbe4246c93afdcba15e4e31b62623b6fa7c4e7eaeaa59.2w_KVA5GZFu7Pzznsiz1foLdxJ9vqynNzNWuJaG8UTA
+ hash: v1.k794b7964.a7f6a336ea69706fbf9c906d3548f0b772d465d9d867dabaa64af73088580d19.dPuzPuRnzJGd1m5ZyaPlBHt5OvuYmyDjwqxRyDiCzDE
products-workflows-editor-tree--new-workflow--light:
- hash: v1.k794b7964.f428395994d5cb9fbb67f38455cbdba988bcbad68dfc188eace678cfb64f8ba6.74P4jM8iVvT0VIBF85CJunsA-8LY9k4sQVDz2vPh-_M
+ hash: v1.k794b7964.b26c001de2fec999dbf8cc7a5cb5e90a125221918565462383596e5954544120.1m0sV-zURViZ0FtU4NAcxq_lqR59MX6e0u93mf4TWhc
products-workflows-editor-tree--pending-ticket-cleanup--dark:
- hash: v1.k794b7964.f3e35fee5efc1de3891aebf6ce42dce5385fa4449128f447000aa3d22a0f0d26.HZKgMmckWM50EtgORZAh7yhANFHg72uVVIxZ24HZvM0
+ hash: v1.k794b7964.2de8be67590d2f1066894e8d3485b6037a3ff773f9290e67719a760106f3e642.vIxviv3sMgP2V_uh31dcntx-1MKtUwtS8GcEGP5OEMM
products-workflows-editor-tree--pending-ticket-cleanup--light:
- hash: v1.k794b7964.4b2921bb3c3109dd0da2a7853102be847ca016f05d5ee4c0f0dcfe162a373df0.E2L3l5xfU8dAaqEgqzUlTX7m28cXn8EyC6uejfboECc
+ hash: v1.k794b7964.58cf54c92e805d3467a646c65999e24754329185c78874fa445e04a6a7eebcf2.CXoA9tIjwJO99F8aFSybnxRmvJMzB2ip3Z-RowWBKNg
products-workflows-editor-tree--renewal-window-alerts--dark:
- hash: v1.k794b7964.b7d7b3df7addfac69919856c99b4b09e86f330d50b353e57837a0939c2665118.sqojt8-aGoj0_7Ut7wrbRSa-9Q7h8kznmIm_ryojYsY
+ hash: v1.k794b7964.9a5bb43c5b9d124cca88f4e2c696103d1ab9d61305c8a8e17b62c227a15b6d70.-CPdH4DReMqjWF2eGilglDR00bid3OvfnKp8g2qfQVc
products-workflows-editor-tree--renewal-window-alerts--light:
- hash: v1.k794b7964.3e0a0d575a1a677fb219d19a88d6d3f9e31ae6e93ebc503dc2a034aac1d0e11a.IcCqn9w0hk0O3Qyjrq31Lajo0QHNWiA34R3S74PHIRI
+ hash: v1.k794b7964.c719df6871c48d89de7ad2f3c5965a56804dceda27b9a452bc27919932a14a10.jQgVO9iXW7sZnojFvL-Rh2Onb1exWc-0EfcCAF7keY4
products-workflows-editor-tree--support-sla-routing--dark:
- hash: v1.k794b7964.c03c94a2ac4a9ab549b0e6a3a844784314975138b0643f6e09bb6b084be124c1.8xknb0pgIYqN3cbOnxAweUyux04dvw2PuPlKmW8EafM
+ hash: v1.k794b7964.411dd0f28eda261f093e7736ce3f58456e8aa70b09d8914116ea14698b24be24.xsESYYjDOqBeoYAUerv0N8ZaXq9q1W_9TX-oHH1Rwac
products-workflows-editor-tree--support-sla-routing--light:
- hash: v1.k794b7964.1990086cf1765af4b068774f55ecf7532c624ebfbb9254ed705a5fad862b939f.RrB4yXhFhYTE3dCOFGhPMc99b7c97wHdADkxHmAhw90
+ hash: v1.k794b7964.57dcc01b1a8941186c56d4313765c1bc324d4d7773052ff59c33e32a76847677.CJpJ9x1W6gNaVt-_vLknTrAf0T8kp_ylQmeJp-aqhSY
products-workflows-reputation--domain-withheld-from-caller--dark:
hash: v1.k794b7964.4c8ae4bd60867d552c0b0499308c93dbb6a9e6da74929a97ddbedd39f992599b.bwSgpaQEan0zikdVKGPrgdoZQY5PMjSXnsfOVCyrrVc
products-workflows-reputation--domain-withheld-from-caller--light:
diff --git a/frontend/src/lib/constants.tsx b/frontend/src/lib/constants.tsx
index ae89325de2f7..89705131059a 100644
--- a/frontend/src/lib/constants.tsx
+++ b/frontend/src/lib/constants.tsx
@@ -614,7 +614,6 @@ export const FEATURE_FLAGS = {
WIZARD_RUN_SYNC: 'wizard-run-sync', // owner: #team-growth multivariate=wizard-session,wizard-run — selects the Wizard sync widget
WIZARD_UI_ENABLED: 'wizard-ui-enabled', // owner: @fercgomes #team-growth — gates the /wizard/runs interface
WORKFLOW_ADD_TO_STATIC_COHORT_ACTION: 'workflow-add-to-static-cohort-action', // owner: #team-workflows
- WORKFLOW_AI_TASK_ACTION: 'workflow-ai-task-action', // owner: @mayteio #team-workflows
WORKFLOW_CLASSIFY_ACTION: 'workflow-classify-action', // owner: #team-workflows
WORKFLOW_OPT_OUT_OF_MESSAGES_ACTION: 'workflow-opt-out-of-messages-action', // owner: #team-workflows
WORKFLOWS_AI_FIRST_NEW: 'workflows-ai-first-new', // owner: @mayteio #team-workflows
diff --git a/frontend/src/scenes/settings/SettingsMap.tsx b/frontend/src/scenes/settings/SettingsMap.tsx
index fb43d46ac527..a64c82548496 100644
--- a/frontend/src/scenes/settings/SettingsMap.tsx
+++ b/frontend/src/scenes/settings/SettingsMap.tsx
@@ -1955,7 +1955,6 @@ export const SETTINGS_MAP: SettingSection[] = [
attrPrefix="workflows-task"
/>
),
- flag: 'WORKFLOW_AI_TASK_ACTION',
keywords: ['workflows', 'ai', 'task', 'agent', 'limit', 'rate', 'cap', 'daily', 'spend', 'pause'],
},
{
diff --git a/products/cdp/backend/api/test/test_hog_function_templates.py b/products/cdp/backend/api/test/test_hog_function_templates.py
index b35eb9bdde81..f445776153c6 100644
--- a/products/cdp/backend/api/test/test_hog_function_templates.py
+++ b/products/cdp/backend/api/test/test_hog_function_templates.py
@@ -335,9 +335,9 @@ class TestHogFunctionTemplates(ClickhouseTestMixin, APIBaseTest, QueryMatchingTe
# an agent that can list it would try to use it and loop on "Template not found". Ordinary
# hidden templates keep being listed (the workflow editor depends on that, see above).
HogFunctionTemplate.objects.create(
- template_id="template-posthog-create-task",
+ template_id="template-posthog-classify",
sha="1.0.0",
- name="Create AI task",
+ name="Classify with AI",
description="A flag-gated template",
code="return event",
code_language="hog",
@@ -353,7 +353,7 @@ class TestHogFunctionTemplates(ClickhouseTestMixin, APIBaseTest, QueryMatchingTe
assert response.status_code == status.HTTP_200_OK, response.json()
listed_ids = [template["id"] for template in response.json()["results"]]
- assert ("template-posthog-create-task" in listed_ids) is flag_enabled
+ assert ("template-posthog-classify" in listed_ids) is flag_enabled
def test_hidden_templates_excluded_from_public_catalog(self):
HogFunctionTemplate.objects.create(
diff --git a/products/cdp/backend/flag_gated_templates.py b/products/cdp/backend/flag_gated_templates.py
index 4f828c4f7b26..6cb4d665e2f7 100644
--- a/products/cdp/backend/flag_gated_templates.py
+++ b/products/cdp/backend/flag_gated_templates.py
@@ -13,7 +13,6 @@ logger = structlog.get_logger(__name__)
# "Template not found". The flag key is shared with FEATURE_FLAGS in
# frontend/src/lib/constants.tsx. Remove an entry when its feature goes GA.
FLAG_GATED_TEMPLATE_IDS = {
- "template-posthog-create-task": "workflow-ai-task-action",
"template-posthog-classify": "workflow-classify-action",
"template-posthog-add-to-static-cohort": "workflow-add-to-static-cohort-action",
"template-posthog-opt-out-of-messages": "workflow-opt-out-of-messages-action",
diff --git a/products/tasks/backend/facade/api.py b/products/tasks/backend/facade/api.py
index a7fe45f023e1..cd979a9d3e67 100644
--- a/products/tasks/backend/facade/api.py
+++ b/products/tasks/backend/facade/api.py
@@ -11326,7 +11326,7 @@ def start_space_setup(
):
raise SpaceSetupUnavailableError(
"Goal setup is not available because the Create AI task workflow action is unavailable. "
- "Ask an administrator to sync workflow templates and enable the action, then retry setup."
+ "Ask an administrator to sync workflow templates, then retry setup."
)
with transaction.atomic():
channel = _locked_visible_channel(channel_id, team.id, user_id)
diff --git a/products/tasks/docs/CHANNELS.md b/products/tasks/docs/CHANNELS.md
index d206c4048a10..e16529acc6b6 100644
--- a/products/tasks/docs/CHANNELS.md
+++ b/products/tasks/docs/CHANNELS.md
@@ -73,13 +73,13 @@ The endpoint posts a `space_setup_started` feed message with `kind`, `subject`,
A feed write failure does not cancel setup.
The endpoint requires the same public API scopes it grants to the setup task. The task can write tasks, canvases, workflows, and its own context page; it has read access to the project data it uses for research.
User text stays in JSON-encoded data blocks in the setup and loop prompts.
-Goal setup returns 503 without starting a task when `template-posthog-create-task` is missing or the `workflow-ai-task-action` flag is disabled for the project.
+Goal setup returns 503 without starting a task when `template-posthog-create-task` is missing.
Sync HogFunction templates after the CDP API starts, then retry setup.
The context prompt includes the server's `team_id` and `channel_id` so a new Space page passes wiki validation.
When no eligible population exists, setup records the measure as unknown and does not invent a target. The loops still start enabled; the Plan loop keeps trying to verify the measure on each run.
Before enabling `code-space-setup`, deploy the setup endpoint and sync the workflow templates.
-Enable `workflow-ai-task-action` for the target project and `loops` for its Desktop users.
+Enable `loops` for the target project's Desktop users.
Reconcile enabled context wikis before rollout so legacy `channels/` pages move under `projects/<project-id>/spaces/`.
Verify a setup in a test project: the Context page saves with `autonomy: propose`, the plan and status keys hold the first plan, all four goal loops appear enabled, and their test runs succeed.
Keep the setup flag off if any dependency check fails.
diff --git a/products/workflows/backend/tests/api/test_hog_flow.py b/products/workflows/backend/tests/api/test_hog_flow.py
index 390d926a9b34..4c190eba2efc 100644
--- a/products/workflows/backend/tests/api/test_hog_flow.py
+++ b/products/workflows/backend/tests/api/test_hog_flow.py
@@ -7800,12 +7800,27 @@ def _create_task_template() -> dict:
return template
+def _classify_template() -> dict:
+ template = deepcopy(webhook_template)
+ template["id"] = "template-posthog-classify"
+ template["name"] = "Classify with AI"
+ template["inputs_schema"] = [
+ {"key": "question", "type": "string", "label": "Question", "secret": False, "required": True},
+ {"key": "categories", "type": "dictionary", "label": "Categories", "secret": False, "required": True},
+ {"key": "model", "type": "choice", "label": "Model", "secret": False, "required": False},
+ ]
+ return template
+
+
+_CLASSIFY_INPUTS = {"question": {"value": "Which team?"}, "categories": {"value": {"spam": "x", "support": "help"}}}
+
+
class TestFlagGatedTemplates(APIBaseTest):
def setUp(self):
super().setUp()
- sync_template_to_db(_create_task_template())
+ sync_template_to_db(_classify_template())
- def _post_flow_with_create_task_action(self):
+ def _post_flow_with_gated_action(self):
trigger_action = {
"id": "trigger_node",
"name": "trigger_1",
@@ -7819,7 +7834,7 @@ class TestFlagGatedTemplates(APIBaseTest):
"id": "action_1",
"name": "action_1",
"type": "function",
- "config": {"template_id": "template-posthog-create-task", "inputs": {"prompt": {"value": "Investigate"}}},
+ "config": {"template_id": "template-posthog-classify", "inputs": _CLASSIFY_INPUTS},
}
# The MCP client header selects strict validation - the path agents and API callers
# actually use. Web-client draft saves stay lenient; the gate holds at publish there.
@@ -7829,7 +7844,7 @@ class TestFlagGatedTemplates(APIBaseTest):
HTTP_X_POSTHOG_CLIENT="mcp",
)
- def _post_flow_with_create_task_action_as_web(self):
+ def _post_flow_with_gated_action_as_web(self):
trigger_action = {
"id": "trigger_node",
"name": "trigger_1",
@@ -7843,7 +7858,7 @@ class TestFlagGatedTemplates(APIBaseTest):
"id": "action_1",
"name": "action_1",
"type": "function",
- "config": {"template_id": "template-posthog-create-task", "inputs": {"prompt": {"value": "Investigate"}}},
+ "config": {"template_id": "template-posthog-classify", "inputs": _CLASSIFY_INPUTS},
}
return self.client.post(
f"/api/projects/{self.team.id}/hog_flows",
@@ -7857,22 +7872,22 @@ class TestFlagGatedTemplates(APIBaseTest):
]
)
def test_gated_template_requires_feature_flag(self, _name, flag_enabled, expected_status):
- # The builder hides the AI task step behind a flag, but agents and API callers write
+ # The builder hides the classify step behind a flag, but agents and API callers write
# workflows through this endpoint directly - without the server-side gate they could
# attach the step on any team.
with patch(
"products.workflows.backend.presentation.views.hog_flow.gated_template_enabled", return_value=flag_enabled
) as mock_gate:
- response = self._post_flow_with_create_task_action()
+ response = self._post_flow_with_gated_action()
assert response.status_code == expected_status, response.json()
- assert mock_gate.call_args.args[0] == "workflow-ai-task-action"
+ assert mock_gate.call_args.args[0] == "workflow-classify-action"
if expected_status == status.HTTP_400_BAD_REQUEST:
assert "Template not found" in response.json()["detail"]
def test_invocation_rejects_an_inline_gated_step_when_the_flag_is_off(self):
with patch("products.workflows.backend.presentation.views.hog_flow.gated_template_enabled", return_value=True):
- created = self._post_flow_with_create_task_action_as_web()
+ created = self._post_flow_with_gated_action_as_web()
assert created.status_code == status.HTTP_201_CREATED
flow = created.json()
@@ -7893,11 +7908,11 @@ class TestFlagGatedTemplates(APIBaseTest):
"products.cdp.backend.flag_gated_templates.posthoganalytics.feature_enabled",
side_effect=Exception("flag service down"),
):
- assert gated_template_enabled("workflow-ai-task-action", self.team) is False
+ assert gated_template_enabled("workflow-classify-action", self.team) is False
def _create_active_flow_with_gated_step(self) -> str:
with patch("products.workflows.backend.presentation.views.hog_flow.gated_template_enabled", return_value=True):
- response = self._post_flow_with_create_task_action()
+ response = self._post_flow_with_gated_action()
assert response.status_code == status.HTTP_201_CREATED, response.json()
flow_id = response.json()["id"]
activate = self.client.patch(
@@ -7939,7 +7954,7 @@ class TestFlagGatedTemplates(APIBaseTest):
# draft. Grandfathering must not treat that as authorization: activation re-checks the
# flag, or the draft path becomes a gate bypass.
with patch("products.workflows.backend.presentation.views.hog_flow.gated_template_enabled", return_value=False):
- create = self._post_flow_with_create_task_action_as_web()
+ create = self._post_flow_with_gated_action_as_web()
assert create.status_code == status.HTTP_201_CREATED, create.json()
flow_id = create.json()["id"]
@@ -7958,7 +7973,7 @@ class TestFlagGatedTemplates(APIBaseTest):
"id": "action_2",
"name": "action_2",
"type": "function",
- "config": {"template_id": "template-posthog-create-task", "inputs": {"prompt": {"value": "Another"}}},
+ "config": {"template_id": "template-posthog-classify", "inputs": _CLASSIFY_INPUTS},
}
with patch("products.workflows.backend.presentation.views.hog_flow.gated_template_enabled", return_value=False):
response = self.client.patch(
@@ -8000,12 +8015,11 @@ class TestCreateTaskActionValidation(APIBaseTest):
}
# Strict validation, same as any programmatic caller - the path a misconfigured
# workflow is actually authored through.
- with patch("products.workflows.backend.presentation.views.hog_flow.gated_template_enabled", return_value=True):
- return self.client.post(
- f"/api/projects/{self.team.id}/hog_flows",
- {"name": "Test Flow", "actions": [trigger_action, action], "edges": []},
- HTTP_X_POSTHOG_CLIENT="mcp",
- )
+ return self.client.post(
+ f"/api/projects/{self.team.id}/hog_flows",
+ {"name": "Test Flow", "actions": [trigger_action, action], "edges": []},
+ HTTP_X_POSTHOG_CLIENT="mcp",
+ )
def test_rejects_a_connector_the_workflow_owner_cannot_mount(self):
response = self._post_flow({"connectors": {"value": ["nonexistent-installation"]}})
@@ -8783,15 +8797,7 @@ class TestRunScoutActionValidation(APIBaseTest):
class TestClassifyActionValidation(APIBaseTest):
def setUp(self):
super().setUp()
- template = deepcopy(webhook_template)
- template["id"] = "template-posthog-classify"
- template["name"] = "Classify with AI"
- template["inputs_schema"] = [
- {"key": "question", "type": "string", "label": "Question", "secret": False, "required": True},
- {"key": "categories", "type": "dictionary", "label": "Categories", "secret": False, "required": True},
- {"key": "model", "type": "choice", "label": "Model", "secret": False, "required": False},
- ]
- sync_template_to_db(template)
+ sync_template_to_db(_classify_template())
def _post_flow(self, categories: dict, question: str = "Which team?", model: str | None = None):
trigger_action = {
diff --git a/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.test.ts b/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.test.ts
index 98b806ff89ef..58335c2c3009 100644
--- a/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.test.ts
+++ b/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.test.ts
@@ -27,7 +27,7 @@ describe('workflowStepCatalog', () => {
it('lists every step a workflow can always add, in the order the step picker shows them', () => {
expect(listed({})).toEqual({
Dispatch: ['Email', 'SMS', 'Slack', 'Webhook'],
- AI: ['Run scout', 'Replay Vision'],
+ AI: ['Create AI task', 'Run scout', 'Replay Vision'],
Delays: ['Delay', 'Time window', 'Wait until'],
'Audience split': ['Conditional branch', 'Cohort branch'],
'PostHog actions': ['Set variable', 'Capture event', 'Update person property', 'Set group property'],
@@ -37,27 +37,19 @@ describe('workflowStepCatalog', () => {
it.each([
{
- name: 'adds the AI task and classify steps behind their flags',
- context: {
- featureFlags: {
- [FEATURE_FLAGS.WORKFLOW_AI_TASK_ACTION]: true,
- [FEATURE_FLAGS.WORKFLOW_CLASSIFY_ACTION]: true,
- },
- },
+ name: 'adds the classify step behind its flag',
+ context: { featureFlags: { [FEATURE_FLAGS.WORKFLOW_CLASSIFY_ACTION]: true } },
ai: ['Create AI task', 'Run scout', 'Classify with AI', 'Replay Vision'],
},
{
name: 'leaves the main-environment steps out of another environment',
- context: {
- featureFlags: { [FEATURE_FLAGS.WORKFLOW_AI_TASK_ACTION]: true },
- currentTeam: { id: 2, project_id: 1 },
- },
+ context: { currentTeam: { id: 2, project_id: 1 } },
ai: ['Create AI task'],
},
{
name: 'leaves the main-environment steps out while the team loads',
context: { currentTeam: null },
- ai: undefined,
+ ai: ['Create AI task'],
},
])('$name', ({ context, ai }) => {
expect(listed(context).AI).toEqual(ai)
diff --git a/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.ts b/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.ts
index 8c03eab98fee..160dbc3bb3fe 100644
--- a/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.ts
+++ b/products/workflows/frontend/Workflows/hogflows/workflowStepCatalog.ts
@@ -229,7 +229,7 @@ function dispatchSteps({ featureFlags }: StepCatalogContext): CreateActionType[]
function aiSteps({ featureFlags, currentTeam }: StepCatalogContext): CreateActionType[] {
const mainEnvironment = isMainEnvironment(currentTeam)
return [
- ...(featureFlags[FEATURE_FLAGS.WORKFLOW_AI_TASK_ACTION] ? [AI_TASK_ACTION_NODE] : []),
+ AI_TASK_ACTION_NODE,
...(mainEnvironment ? [RUN_SCOUT_ACTION_NODE] : []),
...(featureFlags[FEATURE_FLAGS.WORKFLOW_CLASSIFY_ACTION] ? [CLASSIFY_ACTION_NODE] : []),
...(mainEnvironment ? [REPLAY_VISION_ACTION_NODE] : []),