What's the most appropriate type of index to use for this function-based query?
The list of expressions for an index must be put between parentheses on table_name (a,b,c). If the index expression is not just a column name, the expression itself must be enclosed with parentheses as well:

CREATE INDEX my_article_idx 
   ON mydb_article ( (regexp_replace(url, '\?.*$', '')) );