Viewing disk usage of temporary buffers of running queries in Postgres
If you have queries generating temporary files, it could indicate that work_mem is not sufficiently sized or that the query is not optimised.

Try setting the parameter log_temp_files = 0 in your postgresql.conf.  This will log the creation of temporary files and the statement being executed.

Additionally an explain analyze of your query may show disk sort happening.  

Taking the log output, you will see the size of temp  files created by your query.  You can use this to either fine tune the query or fine tune the work_mem parameter.